[Stencil] Problems following the Stencil tutorial

I’m trying to follow the tutorial here but running into a couple of problems:

  • “Open src/components/my-name/my-name.tsx in your editor”: as far as I can see there is no such file in the repository
  • “npm test”: there are several tests in the “dist/dependencies/components/tests” directory that fail.
  • “npm start” runs an app that doesn’t seem to do much of anything. There’r a Button ‘Profile Page’ but it doesn’t go anywhere.

Am I missing something?

They’ve pushed two updates in the last few days. The docs are way behind.

You’re probably on a Windows machine. If so, the failure of npm test is a known issue (#428).

I’d suggest you find examples of working Stencil apps and follow them, and join the Slack channel. Learning from the docs is going to be frustrating for a while. (Though for all I know, they’ll update the site by the end of the day. But maybe not.)

One thing I’ve built is here, if that helps. But the syntax of stencil.config.js is no longer the same, and I haven’t updated yet. (My plugin works, but it is only a good example in some places.)

Good luck.

Thanks for the response. I’m on a Linux machine so should maybe add a comment to issue #428. I tried to join the Slack channel but it tells me to “Contact the workspace administrator for an invitation”, not sure who that is! I’ll certainly take a look at your component.

This is a better example to follow actually, I just checked and it doesn’t have the stencil.config.js issue. The first one was built with 0.2.3, and this one was built with 0.4.1.