Skip to content

Commit

Permalink
Fix some TypeScript and build issues
Browse files Browse the repository at this point in the history
  • Loading branch information
matthew-dean committed Apr 2, 2023
1 parent 7181a98 commit 4e4f64a
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 7 deletions.
4 changes: 2 additions & 2 deletions packages/less/package.json
Expand Up @@ -41,9 +41,9 @@
"lint:fix": "eslint '**/*.{ts,js}' --fix",
"build": "npm-run-all clean compile",
"clean": "shx rm -rf ./lib tsconfig.tsbuildinfo",
"compile": "tsc -p tsconfig.json",
"compile": "tsc -p tsconfig.build.json",
"copy:root": "shx cp -rf ./dist ../../",
"dev": "tsc -p tsconfig.json -w",
"dev": "tsc -p tsconfig.build.json -w",
"prepublishOnly": "grunt dist"
},
"optionalDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/less/test/test-es6.ts
Expand Up @@ -5,13 +5,13 @@ import less from '..';
const lessRender = less.render;

// then I call lessRender on something
const y = lessRender(`
lessRender(`
body {
a: 1;
b: 2;
c: 30;
d: 4;
}`, {sourceMap: {}}, function(error, output) {
}`, {sourceMap: {}}, function(error: any, output: any) {
if (error)
console.error(error)
})
7 changes: 7 additions & 0 deletions packages/less/tsconfig.build.json
@@ -0,0 +1,7 @@
{
"extends": "./tsconfig",
"compilerOptions": {
"rootDir": "./src",
},
"include": ["src/**/*"]
}
6 changes: 3 additions & 3 deletions packages/less/tsconfig.json
@@ -1,7 +1,7 @@
{
"compilerOptions": {
"outDir": "./lib",
"rootDir": "./src",
"rootDir": ".",
"allowJs": true,
"sourceMap": true,
"inlineSources": true,
Expand All @@ -15,6 +15,6 @@
"rootDir": "."
}
},
"include": ["src/**/*"],
"exclude": ["node_modules"]
"include": ["**/*"],
"exclude": ["node_modules", "lib/**/*"]
}

0 comments on commit 4e4f64a

Please sign in to comment.