1.0.0 • Published 1 year ago
productivitytools.learning.typescript.npmpackage v1.0.0
Doing tutorial
npm init -y
npm add -D typescript react react-dom @types/react
- create package
- create tsconfig.json file
{
"compilerOptions": {
"strict": true,
"jsx": "react",
"declaration": true,
"esModuleInterop": true,
"outDir": "dist",
"target": "es6",
"module": "es6",
"moduleResolution": "node"
},
"include": ["src"]
}
add script to package.json
"clean": "rm -rf dist",
"build": "npm run clean && tsc && cp package.json README.md ./dist",
- buld it
npm run build
1.0.0
1 year ago