Skip to content

Commit 2575863

Browse files
committed
chore: bump version
1 parent 6879782 commit 2575863

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+134
-125
lines changed

.changeset/fuzzy-shoes-tie.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"tailwindcss-patch": major
3+
---
4+
5+
feat: prefer esm

.changeset/selfish-hornets-swim.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@tailwindcss-mangle/core": major
3+
---
4+
5+
feat: prefer esm

packages/config/test/index.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { resolve } from 'node:path'
1+
import { resolve } from 'pathe'
22
import { configName } from '@/constants'
33
import { getDefaultMangleUserConfig, getDefaultUserConfig } from '@/defaults'
44
import { getConfig, initConfig } from '@/index'

packages/config/test/utils.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
import path from 'node:path'
1+
import path from 'pathe'
22

33
export const fixturesRoot = path.resolve(__dirname, './fixtures')

packages/config/vitest.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import path from 'node:path'
1+
import path from 'pathe'
22
import { defineProject } from 'vitest/config'
33

44
export default defineProject({

packages/core/build.config.ts

Lines changed: 0 additions & 19 deletions
This file was deleted.

packages/core/package.json

Lines changed: 20 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
{
22
"name": "@tailwindcss-mangle/core",
3+
"type": "module",
34
"version": "3.0.0",
45
"description": "The core of tailwindcss-mangle",
56
"author": "SonOfMagic <[email protected]>",
@@ -20,14 +21,14 @@
2021
],
2122
"exports": {
2223
".": {
23-
"types": "./dist/index.d.ts",
24-
"import": "./dist/index.mjs",
25-
"require": "./dist/index.cjs"
24+
"types": "./src/index.ts",
25+
"import": "./src/index.ts",
26+
"require": "./src/index.ts"
2627
}
2728
},
28-
"main": "./dist/index.cjs",
29-
"module": "./dist/index.mjs",
30-
"types": "./dist/index.d.ts",
29+
"main": "./src/index.ts",
30+
"module": "./src/index.ts",
31+
"types": "./src/index.ts",
3132
"typesVersions": {
3233
"*": {
3334
"*": [
@@ -40,15 +41,25 @@
4041
"dist"
4142
],
4243
"scripts": {
43-
"dev": "unbuild --sourcemap",
44-
"build": "unbuild",
44+
"dev": "tsup --watch --sourcemap",
45+
"build": "tsup",
4546
"test": "vitest run --coverage.enabled",
4647
"test:dev": "vitest",
4748
"coverage": "vitest run --coverage"
4849
},
4950
"publishConfig": {
5051
"access": "public",
51-
"registry": "https://registry.npmjs.org/"
52+
"registry": "https://registry.npmjs.org/",
53+
"exports": {
54+
".": {
55+
"types": "./dist/index.d.ts",
56+
"import": "./dist/index.js",
57+
"require": "./dist/index.cjs"
58+
}
59+
},
60+
"main": "./dist/index.cjs",
61+
"module": "./dist/index.js",
62+
"types": "./dist/index.d.ts"
5263
},
5364
"dependencies": {
5465
"@ast-core/escape": "^1.0.1",

packages/core/test/utils/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import fs from 'node:fs'
2-
import path from 'node:path'
2+
import path from 'pathe'
33
import postcss from 'postcss'
44
import tailwindcss from 'tailwindcss'
55

packages/core/vitest.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import path from 'node:path'
1+
import path from 'pathe'
22
import { defineProject } from 'vitest/config'
33

44
export default defineProject({

packages/shared/src/utils.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,14 @@
1+
import { createDefu } from 'defu'
2+
3+
export { defu } from 'defu'
4+
5+
export const defuOverrideArray = createDefu((obj, key, value) => {
6+
if (Array.isArray(obj[key]) && Array.isArray(value)) {
7+
obj[key] = value
8+
return true
9+
}
10+
})
11+
112
export const preserveClassNames = [
213
// https://tailwindcss.com/docs/transition-timing-function start
314
// https://github.com/sonofmagic/tailwindcss-mangle/issues/21

0 commit comments

Comments
 (0)