Skip to content

Commit

Permalink
expand NPM install instructions (#4952)
Browse files Browse the repository at this point in the history
  • Loading branch information
swift502 authored Nov 20, 2024
1 parent cc65ec4 commit 807241a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions packages/model-viewer/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ supported to provide a seamless development experience.

## Installing

### NPM

The `<model-viewer>` web component can be installed from [NPM](https://npmjs.org):

```sh
Expand All @@ -30,6 +32,14 @@ npm install three
npm install @google/model-viewer
```

Finally, include the `<model-viewer>` script in your project.

```js
import '@google/model-viewer';
```

### CDN

It can also be used directly from various free CDNs such as [jsDelivr](https://www.jsdelivr.com/package/npm/@google/model-viewer) and Google's own [hosted libraries](https://developers.google.com/speed/libraries#model-viewer):

```html
Expand Down

0 comments on commit 807241a

Please sign in to comment.