0

I have v2 addon and I was create files manually, I want to be create in terminal to create components, service, utils,…etc.

I tried in v2 addon path of create component but it will get error!

PS C:\V2 Testing\v2-addon> ember generate component sample2

Unknown blueprint: component

I want to be create in terminal to create components, service, utils,…etc.

1 Answer 1

0

there is no generator for v2 addons at this time.

i create components by just right clicking a folder and selecting new file

I want to be create in terminal to create components, service, utils,…etc.

all of these can be done with your editor -- no need for a special tool

example: https://github.com/universal-ember/ember-primitives/tree/main/ember-primitives/src

if you have to support non strict mode, make sure you fill out the appReexports plugin options https://github.com/universal-ember/ember-primitives/blob/main/ember-primitives/rollup.config.mjs#L20

defaults:

    addon.appReexports([
      'components/**/*.js',
      'helpers/**/*.js',
      'modifiers/**/*.js',
      'services/**/*.js',
    ]),

also note that utils are not an ember concept and had no business being in the old generator

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.