Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: tsup to unbuild and node 16 to 18 #311

Merged
merged 2 commits into from
Aug 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
// This tells ESLint to load the config from the package `eslint-config-custom`
"extends": ["custom", "plugin:storybook/recommended"],
"rules": {
"vue/one-component-per-file": "off"
"vue/one-component-per-file": "off",
"n/prefer-global/process": "off"
// "no-console": "off"
},
"overrides": [
Expand Down
5 changes: 5 additions & 0 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@
"dependsOn": [
"^build"
]
},
"clean": {
"dependsOn": [
"^clean"
]
}
}
}
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@
"coverage": "vitest run --coverage",
"build:storybook": "pnpm storybook build",
"typecheck": "tsc --noEmit",
"clean": "rimraf 'packages/**/node_modules' 'playground/**/node_modules' 'node_modules'",
"clean": "pnpm nx run-many -t clean",
"clean:node": "rimraf 'packages/**/node_modules' 'playground/**/node_modules' 'node_modules'",
"clean:dist": "rimraf 'packages/**/dist' 'playground/**/dist'",
"clean:dts": "rimraf 'playground/vue3/src/components.d.ts' 'playground/vue3/src/auto-imports.d.ts' 'playground/nuxt3/.nuxt'",
"update:version": "esno scripts/update-version.ts"
Expand Down
3 changes: 2 additions & 1 deletion packages/components/arrow/build.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { defineBuildConfig } from 'unbuild'

const isClean = (process.env.CLEAN || 'false') === 'true'
export default defineBuildConfig({
declaration: true,
clean: true,
clean: isClean,
})
5 changes: 3 additions & 2 deletions packages/components/arrow/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,9 @@
"node": ">=18"
},
"scripts": {
"build": "tsup",
"dev": "tsup --watch"
"build": "unbuild",
"dev": "unbuild --stub",
"clean": "rimraf ./dist && rimraf ./node_modules"
},
"peerDependencies": {
"vue": "^3.3.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/components/arrow/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "tsconfig/node16.json",
"extends": "tsconfig/node18.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "dist"
Expand Down
22 changes: 0 additions & 22 deletions packages/components/arrow/tsup.config.ts

This file was deleted.

11 changes: 3 additions & 8 deletions packages/components/aspect-ratio/build.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
import { defineBuildConfig } from 'unbuild'

const isClean = (process.env.CLEAN || 'false') === 'true'
export default defineBuildConfig({
entries: [
{
builder: 'mkdist',
input: './src/',
pattern: ['**', '!stories'],
declaration: true,
},
],
declaration: true,
clean: isClean,
})
5 changes: 3 additions & 2 deletions packages/components/aspect-ratio/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,9 @@
"node": ">=18"
},
"scripts": {
"build": "tsup",
"dev": "tsup --watch"
"build": "unbuild",
"dev": "unbuild --stub",
"clean": "rimraf ./dist && rimraf ./node_modules"
},
"peerDependencies": {
"vue": "^3.3.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/components/aspect-ratio/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "tsconfig/node16.json",
"extends": "tsconfig/node18.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "dist"
Expand Down
22 changes: 0 additions & 22 deletions packages/components/aspect-ratio/tsup.config.ts

This file was deleted.

9 changes: 2 additions & 7 deletions packages/components/avatar/build.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
import { defineBuildConfig } from 'unbuild'

const isClean = (process.env.CLEAN || 'false') === 'true'
export default defineBuildConfig({
entries: [
{
builder: 'mkdist',
input: './src/',
pattern: ['**/!(*.test|*.stories).ts'],
},
],
declaration: true,
clean: isClean,
})
5 changes: 3 additions & 2 deletions packages/components/avatar/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,9 @@
"node": ">=18"
},
"scripts": {
"build": "tsup",
"dev": "tsup --watch"
"build": "unbuild",
"dev": "unbuild --stub",
"clean": "rimraf ./dist && rimraf ./node_modules"
},
"peerDependencies": {
"vue": "^3.3.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/components/avatar/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "tsconfig/node16.json",
"extends": "tsconfig/node18.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "dist"
Expand Down
22 changes: 0 additions & 22 deletions packages/components/avatar/tsup.config.ts

This file was deleted.

9 changes: 2 additions & 7 deletions packages/components/checkbox/build.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
import { defineBuildConfig } from 'unbuild'

const isClean = (process.env.CLEAN || 'false') === 'true'
export default defineBuildConfig({
entries: [
{
builder: 'mkdist',
input: './src/',
pattern: ['**/!(*.test|*.stories).ts'],
},
],
declaration: true,
clean: isClean,
})
7 changes: 4 additions & 3 deletions packages/components/checkbox/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,15 @@
"node": ">=18"
},
"scripts": {
"build": "tsup",
"dev": "tsup --watch"
"build": "unbuild",
"dev": "unbuild --stub",
"clean": "rimraf ./dist && rimraf ./node_modules"
},
"peerDependencies": {
"vue": "^3.3.0"
},
"dependencies": {
"@oku-ui/presence": "workspace:^",
"@oku-ui/presence": "latest",
"@oku-ui/primitive": "latest",
"@oku-ui/provide": "latest",
"@oku-ui/use-composable": "latest",
Expand Down
2 changes: 1 addition & 1 deletion packages/components/checkbox/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "tsconfig/node16.json",
"extends": "tsconfig/node18.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "dist"
Expand Down
22 changes: 0 additions & 22 deletions packages/components/checkbox/tsup.config.ts

This file was deleted.

9 changes: 2 additions & 7 deletions packages/components/collapsible/build.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
import { defineBuildConfig } from 'unbuild'

const isClean = (process.env.CLEAN || 'false') === 'true'
export default defineBuildConfig({
entries: [
{
builder: 'mkdist',
input: './src/',
pattern: ['**/!(*.test|*.stories).ts'],
},
],
declaration: true,
clean: isClean,
})
7 changes: 4 additions & 3 deletions packages/components/collapsible/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,12 @@
"dist"
],
"scripts": {
"build": "tsup",
"dev": "tsup --watch"
"build": "unbuild",
"dev": "unbuild --stub",
"clean": "rimraf ./dist && rimraf ./node_modules"
},
"peerDependencies": {
"vue": "^3.3.2"
"vue": "^3.3.4"
},
"dependencies": {
"@oku-ui/presence": "latest",
Expand Down
2 changes: 1 addition & 1 deletion packages/components/collapsible/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "tsconfig/node16.json",
"extends": "tsconfig/node18.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "dist"
Expand Down
22 changes: 0 additions & 22 deletions packages/components/collapsible/tsup.config.ts

This file was deleted.

9 changes: 2 additions & 7 deletions packages/components/collection/build.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
import { defineBuildConfig } from 'unbuild'

const isClean = (process.env.CLEAN || 'false') === 'true'
export default defineBuildConfig({
entries: [
{
builder: 'mkdist',
input: './src/',
pattern: ['**/!(*.test|*.stories).ts'],
},
],
declaration: true,
clean: isClean,
})
5 changes: 3 additions & 2 deletions packages/components/collection/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,9 @@
"node": ">=18"
},
"scripts": {
"build": "tsup",
"dev": "tsup --watch"
"build": "unbuild",
"dev": "unbuild --stub",
"clean": "rimraf ./dist && rimraf ./node_modules"
},
"peerDependencies": {
"vue": "^3.3.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/components/collection/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "tsconfig/node16.json",
"extends": "tsconfig/node18.json",
"compilerOptions": {
"rootDir": "src",
"outDir": "dist"
Expand Down
22 changes: 0 additions & 22 deletions packages/components/collection/tsup.config.ts

This file was deleted.

9 changes: 2 additions & 7 deletions packages/components/direction/build.config.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,7 @@
import { defineBuildConfig } from 'unbuild'

const isClean = (process.env.CLEAN || 'false') === 'true'
export default defineBuildConfig({
entries: [
{
builder: 'mkdist',
input: './src/',
pattern: ['**/!(*.test|*.stories).ts'],
},
],
declaration: true,
clean: isClean,
})
Loading