0

What is the correct way to define theme in theme.js

dev/tools/grunt/configs/themes.js

My theme in app/design is Hose/Fit

<theme>: {
  area: '<area>',
  name: '<Vendor>/<theme>,
  locale: '<language>',
  files: [
    '<path_to_file1>', //path to root source file
    '<path_to_file2>'
  ],
dsl: 'less'
}

1 Answer 1

0

Use file dev/tools/grunt/configs/local-themes.js, and define your theme as any other:

    fit: {
        area: 'frontend',
        name: 'Hose/Fit',
        locale: 'en_US',
        files: [
            'css/styles-m',
            'css/styles-l'
        ],
        dsl: 'less'
    },

The files array is a destinations of your generated styles eg pub/static/frontend/Magento/blank/en_US/css/styles-m.css

Remember that grunt is only for development purposes, you won't need it in production enviroment.

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.