I used ember-browserify to add pkijs to a TypeScript project today. Here are some notes:
- add the library:
yarn add pkijs --dev
- add the type declarations:
yarn add @types/pkijs --dev
- add
"npm:pkijs": [ "node_modules/pkijs" ], to compilerOptions.paths in tsconfig.json. This tells Typescript that when I import PKI from 'npm:pkijs', I'm getting node_modules/pkijs/src/index.js
import PKI from 'npm:pkijs' in a component/route/model/...
I don't know where this information might be useful -- possibly in the README.
I used ember-browserify to add pkijs to a TypeScript project today. Here are some notes:
yarn add pkijs --devyarn add @types/pkijs --dev"npm:pkijs": [ "node_modules/pkijs" ],tocompilerOptions.pathsintsconfig.json. This tells Typescript that when Iimport PKI from 'npm:pkijs', I'm gettingnode_modules/pkijs/src/index.jsimport PKI from 'npm:pkijs'in a component/route/model/...I don't know where this information might be useful -- possibly in the README.