0

I am checking coding standards of my module. I face this warning in technical report

Spaces must be used to indent lines; tabs are not allowed

public function __construct(
    \Magento\Backend\App\Action\Context $context,
    \Magento\Backend\Model\View\Result\ForwardFactory $resultForwardFactory
) {
    $this->resultForwardFactory = $resultForwardFactory;
    parent::__construct($context);
}

For Ex: Here is total 7 lines, I face error at line no 3 even line 2 and 3 have same spaces.

I am using sublime text editor.

How we found that we make tab or space?

1 Answer 1

1

If you click at the start of that line and then click right arrow key. If it directly jump after 4 spaces then you have used tab there. Otherwise it will take you four click to reach 4 places.

I will suggest use of the text editor like Php storm. In it you can directly select and convert all the tabs into spaces.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.