DEV Community

Liz
Liz

Posted on • Updated on

Installing open-wc

The following is a guide on installing open-wc on MacOS:

  1. The install for Node JS can be found at https://nodejs.org/en/. 14.17.5 is recommended due to the stability and lack of necessity for the bleeding edge features.

  2. Yarn can be installed by typing npm install -g yarn into the terminal. sudo may have to be used to complete the install.

  3. In whatever folder you prefer to use, you should be able to run npm init @open-wc. Going through the setup, you select web component, all three tooling options should be highlighted using the spacebar, typescript should not be selected, and the component can be named whatever you like. Finally, it should be installed using yarn.

  4. The component can be started by switching into the project directory and running npm run start. The component will open in a browser window.

Discussion (0)