@homestuck/prettier-config 1.1.0 → 1.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/index.js +11 -14
  3. package/package.json +4 -3
package/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.2.1](https://github.com/homestuck/configs/compare/prettier-config@v1.2.0...prettier-config@v1.2.1) (2025-12-16)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * **prettier:** Change JSDoc type declaration for config, change export file extension from .mjs to .js ([#21](https://github.com/homestuck/configs/issues/21)) ([13f0845](https://github.com/homestuck/configs/commit/13f084580ddb8985a9c30bbd832615d28fbc6438))
9
+
10
+ ## [1.2.0](https://github.com/homestuck/configs/compare/prettier-config@v1.1.0...prettier-config@v1.2.0) (2025-12-15)
11
+
12
+
13
+ ### Features
14
+
15
+ * **prettier:** export Prettier config as ESM instead of CJS ([#9](https://github.com/homestuck/configs/issues/9)) ([2a3e964](https://github.com/homestuck/configs/commit/2a3e9644b1794b2aeaf22e3bbaa07f7a4a6ebd0b))
16
+
3
17
  ## [1.1.0](https://github.com/homestuck/configs/compare/prettier-config@v1.0.1...prettier-config@v1.1.0) (2025-12-11)
4
18
 
5
19
  ## [1.0.1](https://github.com/homestuck/configs/compare/prettier-config@v1.0.0...prettier-config@v1.0.1) (2025-12-09)
package/index.js CHANGED
@@ -1,9 +1,5 @@
1
- /** @typedef {import("prettier").Config} PrettierConfig */
2
- /** @typedef {import("@ianvs/prettier-plugin-sort-imports").PluginConfig} SortImportsConfig */
3
- /** @typedef {import("@prettier/plugin-xml")} XMLConfig */
4
-
5
- /** @type { PrettierConfig | SortImportsConfig | XMLConfig } */
6
- module.exports = {
1
+ /** @type {import("prettier").Config} */
2
+ const config = {
7
3
  arrowParens: 'always',
8
4
  bracketSameLine: true,
9
5
  bracketSpacing: true,
@@ -18,7 +14,7 @@ module.exports = {
18
14
  '^@homestuck/(.*)$',
19
15
  '',
20
16
  '<TYPES>^#',
21
- '^#/(.*)$',
17
+ '^(#/(.*)$)|^(#(.*)$)',
22
18
  '',
23
19
  '<TYPES>^[.|..|~]',
24
20
  '^~/',
@@ -30,11 +26,11 @@ module.exports = {
30
26
  importOrderTypeScriptVersion: '5.9.3',
31
27
  jsonRecursiveSort: true,
32
28
  plugins: [
33
- require.resolve('@ianvs/prettier-plugin-sort-imports'),
34
- require.resolve('@prettier/plugin-xml'),
35
- require.resolve('prettier-plugin-packagejson'),
36
- require.resolve('prettier-plugin-sort-json'),
37
- require.resolve('prettier-plugin-tailwindcss'),
29
+ '@ianvs/prettier-plugin-sort-imports',
30
+ '@prettier/plugin-xml',
31
+ 'prettier-plugin-packagejson',
32
+ 'prettier-plugin-sort-json',
33
+ 'prettier-plugin-tailwindcss',
38
34
  ],
39
35
  printWidth: 80,
40
36
  proseWrap: 'preserve',
@@ -43,9 +39,10 @@ module.exports = {
43
39
  tabWidth: 2,
44
40
  trailingComma: 'all',
45
41
  useTabs: false,
46
- tailwindFunctions: ['classNames', 'clsx', 'cn', 'cva', 'tv', 'tw', 'twMerge'],
42
+ xmlQuoteAttributes: 'double',
47
43
  xmlSelfClosingSpace: true,
48
44
  xmlSortAttributesByKey: true,
49
- xmlQuoteAttributes: 'double',
50
45
  xmlWhitespaceSensitivity: 'preserve',
51
46
  }
47
+
48
+ export default config
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@homestuck/prettier-config",
3
- "version": "1.1.0",
3
+ "version": "1.2.1",
4
4
  "private": false,
5
5
  "description": "Baseline Prettier config used and maintained by Homestuck Inc., et al.",
6
6
  "repository": {
@@ -10,10 +10,11 @@
10
10
  },
11
11
  "license": "MIT",
12
12
  "author": "Homestuck <support@homestuck.com> (https://homestuck.com)",
13
- "type": "commonjs",
13
+ "type": "module",
14
14
  "exports": {
15
15
  ".": "./index.js"
16
16
  },
17
+ "main": "./index.js",
17
18
  "prettier": "@homestuck/prettier-config",
18
19
  "dependencies": {
19
20
  "@ianvs/prettier-plugin-sort-imports": "4.7.0",
@@ -24,7 +25,7 @@
24
25
  "prettier-plugin-tailwindcss": "0.7.2"
25
26
  },
26
27
  "devDependencies": {
27
- "@types/node": "24.10.3",
28
+ "@types/node": "24.10.4",
28
29
  "typescript": "5.9.3",
29
30
  "@homestuck/tsconfig": "1.1.0"
30
31
  },