Skip to content

Commit

Permalink
Add JSPM install and usage documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
mhegazy committed Dec 22, 2016
1 parent e633121 commit d0078f4
Showing 1 changed file with 24 additions and 2 deletions.
26 changes: 24 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,12 @@ npm install tslib
bower install tslib
```

## JSPM

```sh
jspm install npm:tslib
```

# Usage

Set the `importHelpers` compiler option on the command line:
Expand All @@ -36,9 +42,9 @@ or in your tsconfig.json:
}
```

#### For bower users
#### For bower and JSPM users

You will need to add a `paths` mapping for `tslib`, e.g.:
You will need to add a `paths` mapping for `tslib`, e.g. For Bower users:

```json
{
Expand All @@ -53,6 +59,22 @@ You will need to add a `paths` mapping for `tslib`, e.g.:
}
```

For JSPM users:

```json
{
"compilerOptions": {
"module": "System",
"importHelpers": true,
"baseUrl": "./",
"paths": {
"tslib" : ["jspm_packages/npm/tslib@1.3.0/tslib.d.ts"]
}
}
}
```


# Contribute

There are many ways to [contribute](https://github.com/Microsoft/TypeScript/blob/master/CONTRIBUTING.md) to TypeScript.
Expand Down

0 comments on commit d0078f4

Please sign in to comment.