mirror of
https://github.com/iconoir-icons/iconoir
synced 2024-05-20 15:26:41 +02:00
feat: add support for ESM modules (#135)
This commit is contained in:
parent
accaf06456
commit
4356a46550
|
@ -11,7 +11,8 @@
|
|||
"lint": "eslint ./bin/build.js",
|
||||
"lint:fix": "npm run lint -- --fix",
|
||||
"build": "node ./bin/build.js",
|
||||
"prepublish": "node ./bin/prepublish.js"
|
||||
"prepublish": "node ./bin/prepublish.js",
|
||||
"dist": "pnpm m --filter ./packages run dist"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
|
|
@ -4,11 +4,12 @@
|
|||
"description": "React Native library for Iconoir icon set",
|
||||
"main": "dist/index.js",
|
||||
"types": "dist/index.d.ts",
|
||||
"module": "dist/esm/index.js",
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"scripts": {
|
||||
"dist": "tsc",
|
||||
"dist": "tsc -p tsconfig.json && tsc -p tsconfig.esm.json",
|
||||
"prepublish": "npm run dist"
|
||||
},
|
||||
"repository": {
|
||||
|
@ -39,4 +40,4 @@
|
|||
"react-native-svg": "^12.1.1",
|
||||
"typescript": "^4.4.4"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
7
packages/iconoir-react-native/tsconfig.esm.json
Normal file
7
packages/iconoir-react-native/tsconfig.esm.json
Normal file
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"extends": "./tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"module": "esnext",
|
||||
"outDir": "./dist/esm"
|
||||
}
|
||||
}
|
|
@ -4,11 +4,12 @@
|
|||
"description": "React library for Iconoir icon set",
|
||||
"main": "dist/index.js",
|
||||
"types": "dist/index.d.ts",
|
||||
"module": "dist/esm/index.js",
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"scripts": {
|
||||
"dist": "tsc",
|
||||
"dist": "tsc -p tsconfig.json && tsc -p tsconfig.esm.json",
|
||||
"prepublish": "npm run dist"
|
||||
},
|
||||
"repository": {
|
||||
|
@ -35,4 +36,4 @@
|
|||
"react": "^17.0.2",
|
||||
"typescript": "^4.4.4"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
7
packages/iconoir-react/tsconfig.esm.json
Normal file
7
packages/iconoir-react/tsconfig.esm.json
Normal file
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"extends": "./tsconfig.json",
|
||||
"compilerOptions": {
|
||||
"module": "esnext",
|
||||
"outDir": "./dist/esm"
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue