ember-learn / cli-guides

Step-by-step guides and tutorials for using the ember-cli to create apps and addons
https://cli.emberjs.com
MIT License
25 stars 76 forks source link

Update references to component class #223

Closed esquith closed 3 years ago

esquith commented 3 years ago

This line doesn't show up when you run this command anymore

esquith commented 3 years ago

@ijlee2 Will do.

esquith commented 3 years ago

@ijlee2 Looks like the only other times it is mentioned is the 3 times its mentioned in this same file (guides/writing-addons/intro-tutorial.md).

When I went through this tutorial I just assumed the author wanted me to manually create the folder.

ijlee2 commented 3 years ago

Great, thank you for checking. To complete the pull request, can I ask for 2 changes:

1. Update the Ember CLI output from when a developer creates a component. You can use the sample output below, but can you ensure that <component-name> is used instead of foo-bar?

installing component
  create addon/components/foo-bar.hbs
  skip addon/components/foo-bar.js
  tip to add a class, run `ember generate component-class foo-bar`
installing component-test
  create tests/integration/components/foo-bar-test.js
installing component-addon
  create app/components/foo-bar.js

2. In the file guides/writing-addons/intro-tutorial.md, can you update data-filename=addon/templates/components/my-component-name.hbs to data-filename=addon/components/my-component-name.hbs?

esquith commented 3 years ago

@ijlee2 Done! Didn't include the tip line. It looked weird to have it there. Let me know if it absolutely needs to be there.

ijlee2 commented 3 years ago

@esquith Regarding skipping the output line, starting with "tip," I think it may help if the output matches what a developer normally sees. I can see both ways, though.

Since the line isn't too long, maybe we include the tip line for now?

ijlee2 commented 3 years ago

Woops, sorry about that

No worries! :)

esquith commented 3 years ago

@esquith Regarding skipping the output line, starting with "tip," I think it may help if the output matches what a developer normally sees. I can see both ways, though.

Since the line isn't too long, maybe we include the tip line for now?

Sure, just added it.

jenweber commented 3 years ago

I thought we had updated everything already to use component template colocation, but I guess not. Good catch, and thank you very much for the PR!