Commit bdef76e2 authored by nanahira's avatar nanahira

double build

parent 24f84ef6
...@@ -36,6 +36,3 @@ lerna-debug.log* ...@@ -36,6 +36,3 @@ lerna-debug.log*
/data /data
/output /output
/config.yaml /config.yaml
/jsx-runtime/*.d.ts
/jsx-runtime/*.js
/jsx-runtime/*.js.map
This diff is collapsed.
...@@ -2,11 +2,24 @@ ...@@ -2,11 +2,24 @@
"name": "satori-tsx", "name": "satori-tsx",
"description": "TSX support package for Satori element.", "description": "TSX support package for Satori element.",
"version": "1.0.0", "version": "1.0.0",
"main": "jsx-runtime/index.js", "exports": {
"types": "jsx-runtime/index.d.ts", ".": {
"main": "dist/index.cjs",
"module": "dist/index.mjs",
"types": "dist/index.d.ts"
},
"./jsx-runtime": {
"main": "dist/index.cjs",
"module": "dist/index.mjs",
"types": "dist/index.d.ts"
}
},
"scripts": { "scripts": {
"compile:cjs": "esbuild index.ts --outfile=dist/index.cjs --bundle --sourcemap --platform=node --target=es2019 --external:@satorijs/element",
"compile:esm": "esbuild index.ts --outfile=dist/index.mjs --bundle --sourcemap --platform=neutral --target=esnext --external:@satorijs/element",
"compile:types": "tsc --emitDeclarationOnly --declaration",
"lint": "eslint --fix .", "lint": "eslint --fix .",
"build": "rimraf dist && tsc", "build": "rimraf dist && npm run compile:cjs && npm run compile:esm && npm run compile:types",
"test": "jest --passWithNoTests", "test": "jest --passWithNoTests",
"start": "node dist/index.js" "start": "node dist/index.js"
}, },
...@@ -44,6 +57,8 @@ ...@@ -44,6 +57,8 @@
"@types/node": "^18.7.17", "@types/node": "^18.7.17",
"@typescript-eslint/eslint-plugin": "^4.33.0", "@typescript-eslint/eslint-plugin": "^4.33.0",
"@typescript-eslint/parser": "^4.33.0", "@typescript-eslint/parser": "^4.33.0",
"esbuild": "^0.15.7",
"esbuild-register": "^3.3.3",
"eslint": "^7.32.0", "eslint": "^7.32.0",
"eslint-config-prettier": "^8.5.0", "eslint-config-prettier": "^8.5.0",
"eslint-plugin-prettier": "^3.4.1", "eslint-plugin-prettier": "^3.4.1",
......
{ {
"compilerOptions": { "compilerOptions": {
"outDir": "dist",
"module": "commonjs", "module": "commonjs",
"target": "es2021", "target": "es2021",
"esModuleInterop": true, "esModuleInterop": true,
...@@ -11,6 +12,7 @@ ...@@ -11,6 +12,7 @@
"compileOnSave": true, "compileOnSave": true,
"allowJs": true, "allowJs": true,
"include": [ "include": [
"jsx-runtime/**/*.ts", "*.ts",
"src/**/*.ts",
] ]
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment