Skip to content

Commit

Permalink
chore(plugin-less): use Rslib to bundle (#3502)
Browse files Browse the repository at this point in the history
  • Loading branch information
chenjiahan authored Sep 18, 2024
1 parent b5030ff commit d807a6e
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 9 deletions.
3 changes: 0 additions & 3 deletions packages/plugin-less/modern.config.ts

This file was deleted.

12 changes: 6 additions & 6 deletions packages/plugin-less/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,20 @@
"type": "module",
"exports": {
".": {
"types": "./dist-types/index.d.ts",
"types": "./dist/index.d.ts",
"import": "./dist/index.js",
"require": "./dist/index.cjs"
}
},
"main": "./dist/index.cjs",
"types": "./dist-types/index.d.ts",
"types": "./dist/index.d.ts",
"files": [
"dist",
"compiled",
"dist-types"
"compiled"
],
"scripts": {
"build": "modern build",
"dev": "modern build --watch",
"build": "rslib build",
"dev": "rslib build --watch",
"prebundle": "prebundle"
},
"dependencies": {
Expand All @@ -35,6 +34,7 @@
},
"devDependencies": {
"@rsbuild/core": "workspace:*",
"@rslib/core": "0.0.6",
"@scripts/test-helper": "workspace:*",
"@types/less": "^3.0.6",
"less": "^4.2.0",
Expand Down
14 changes: 14 additions & 0 deletions packages/plugin-less/rslib.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { defineConfig } from '@rslib/core';

export default defineConfig({
lib: [
{
format: 'esm',
dts: { bundle: false },
},
{ format: 'cjs' },
],
output: {
target: 'node',
},
});
3 changes: 3 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit d807a6e

Please sign in to comment.