I am trying to create a React TypeScript NPM package. I have finished my code and created package.json
and tsconfig.json
. But inside my package I also have a bunch of CSS files that I want to include in my package. This is my tsconfig.json
:
{
"compilerOptions": {
"outDir": "./dist",
"target": "es5",
"esModuleInterop": true,
"module": "commonjs",
"moduleResolution": "node",
"noImplicitAny": true,
"removeComments": true,
"declaration": true,
"jsx": "react",
"lib": [ "es2015", "dom" ],
"sourceMap": false
},
"files": [
"src/index.tsx"
],
"include": [
"src/**/*"
],
"exclude": [
"node_modules"
]
}
My problem is that when I run tsc
in my folder, it creates all .js
files and all .d.ts
files in /dist
, but I see no CSS files at all. How do I do to make it include CSS?