You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[](https://www.npmjs.com/package/@aurodesignsystem/auro-badge)
In cases where the project is not able to process JS assets, there are pre-processed assets available for use. Legacy browsers such as IE11 are no longer supported.
@@ -113,19 +101,7 @@ In cases where the project is not able to process JS assets, there are pre-proce
In order to develop against this project, if you are not part of the core team, you will be required to fork the project prior to submitting a pull request.
116
+
There are two key parts to every Auro component: the <ahref="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Classes">class</a> and the custom element definition.
117
+
The class defines the component’s behavior, while the custom element registers it under a specific name so it can be used in HTML.
142
118
143
-
Please be sure to review the [contribution guidelines](https://auro.alaskaair.com/contributing) for this project. Please make sure to **pay special attention** to the **conventional commits** section of the document.
119
+
When you install the component as described on the `Install` page, the class is imported automatically, and the component is registered globally for you.
144
120
145
-
<!-- AURO-GENERATED-CONTENT:END -->
146
-
147
-
### Start development environment
121
+
However, if you need to load multiple versions of the same component on a single page (for example, when two projects depend on different versions), you can manually register the class under a custom element name to avoid conflicts.
Once the project has been cloned to your local resource and you have installed all the dependencies you will need to open a shell session to run the **dev server**.
151
-
152
-
```shell
153
-
$ npm run dev
154
-
```
123
+
You can do this by importing only the component class and using the `register(name)` method with a unique name:
Automated tests are required for every Auro component. See `.\test\auro-badge.test.js` for the tests for this component. Run `npm run test` to run the tests and check code coverage. Tests must pass and meet a certain coverage threshold to commit. See [the testing documentation](https://auro.alaskaair.com/support/tests) for more details.
0 commit comments