Skip to content

Commit

Permalink
fix: include minified bundle in npm tarball (#291)
Browse files Browse the repository at this point in the history
Update project config to include the minified bundle.
  • Loading branch information
achingbrain authored Dec 8, 2022
1 parent c03042c commit ac88cba
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 15 deletions.
24 changes: 10 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
## Table of contents <!-- omit in toc -->

- [Install](#install)
- [Browser `<script>` tag](#browser-script-tag)
- [Background](#background)
- [What is multiaddr?](#what-is-multiaddr)
- [Browser: `<script>` Tag](#browser-script-tag)
- [Usage](#usage)
- [API](#api)
- [Resolvers](#resolvers)
Expand All @@ -24,6 +24,15 @@
$ npm i @multiformats/multiaddr
```

### Browser `<script>` tag

Loading this module through a script tag will make the `multiaddr` function available in
the global namespace.

```html
<script src="https://unpkg.com/@multiformats/multiaddr/dist/index.min.js"></script>
```

## Background

### What is multiaddr?
Expand All @@ -36,19 +45,6 @@ A standard way to represent addresses that
- have a nice string representation
- encapsulate well

```sh
npm i multiaddr
```

### Browser: `<script>` Tag

Loading this module through a script tag will make the `Multiaddr` obj available in
the global namespace.

```html
<script src="https://unpkg.com/multiaddr/dist/index.min.js"></script>
```

## Usage

```js
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
},
"files": [
"src",
"dist/src",
"dist",
"!dist/test",
"!**/*.tsbuildinfo"
],
Expand Down

0 comments on commit ac88cba

Please sign in to comment.