@absc_company/prettier 1.0.1 → 1.0.3
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.
- package/dist/index.d.ts +40 -0
- package/dist/index.mjs +14 -0
- package/package.json +14 -6
- package/.prettierrc.js +0 -3
- package/src/index.ts +0 -15
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import type { Config } from 'prettier';
|
|
2
|
+
export type Prettier = Config;
|
|
3
|
+
export declare const prettier: (params?: Prettier) => {
|
|
4
|
+
overrides?: Array<{
|
|
5
|
+
files: string | string[];
|
|
6
|
+
excludeFiles?: string | string[];
|
|
7
|
+
options?: import("prettier").Options;
|
|
8
|
+
}>;
|
|
9
|
+
semi: boolean;
|
|
10
|
+
singleQuote: boolean;
|
|
11
|
+
jsxSingleQuote: boolean;
|
|
12
|
+
trailingComma: string;
|
|
13
|
+
bracketSpacing?: boolean | undefined;
|
|
14
|
+
objectWrap?: "preserve" | "collapse" | undefined;
|
|
15
|
+
bracketSameLine?: boolean | undefined;
|
|
16
|
+
rangeStart?: number | undefined;
|
|
17
|
+
rangeEnd?: number | undefined;
|
|
18
|
+
parser?: import("prettier").LiteralUnion<import("prettier").BuiltInParserName, string> | undefined;
|
|
19
|
+
filepath?: string | undefined;
|
|
20
|
+
requirePragma?: boolean | undefined;
|
|
21
|
+
insertPragma?: boolean | undefined;
|
|
22
|
+
checkIgnorePragma?: boolean | undefined;
|
|
23
|
+
proseWrap?: "always" | "preserve" | "never" | undefined;
|
|
24
|
+
arrowParens: string;
|
|
25
|
+
plugins?: (string | URL | import("prettier").Plugin<any>)[] | undefined;
|
|
26
|
+
htmlWhitespaceSensitivity?: "css" | "strict" | "ignore" | undefined;
|
|
27
|
+
endOfLine?: "auto" | "lf" | "crlf" | "cr" | undefined;
|
|
28
|
+
quoteProps?: "preserve" | "as-needed" | "consistent" | undefined;
|
|
29
|
+
vueIndentScriptAndStyle?: boolean | undefined;
|
|
30
|
+
embeddedLanguageFormatting?: "auto" | "off" | undefined;
|
|
31
|
+
singleAttributePerLine?: boolean | undefined;
|
|
32
|
+
experimentalOperatorPosition?: "start" | "end" | undefined;
|
|
33
|
+
experimentalTernaries?: boolean | undefined;
|
|
34
|
+
jsxBracketSameLine?: boolean | undefined;
|
|
35
|
+
printWidth: number;
|
|
36
|
+
tabWidth: number;
|
|
37
|
+
useTabs: boolean;
|
|
38
|
+
parentParser?: string | undefined | undefined;
|
|
39
|
+
__embeddedInHtml?: boolean | undefined | undefined;
|
|
40
|
+
};
|
package/dist/index.mjs
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
//#region src/index.ts
|
|
2
|
+
const prettier = (params = {}) => ({
|
|
3
|
+
printWidth: 100,
|
|
4
|
+
tabWidth: 2,
|
|
5
|
+
singleQuote: true,
|
|
6
|
+
trailingComma: "none",
|
|
7
|
+
arrowParens: "always",
|
|
8
|
+
semi: true,
|
|
9
|
+
jsxSingleQuote: true,
|
|
10
|
+
useTabs: false,
|
|
11
|
+
...params
|
|
12
|
+
});
|
|
13
|
+
//#endregion
|
|
14
|
+
export { prettier };
|
package/package.json
CHANGED
|
@@ -1,21 +1,29 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@absc_company/prettier",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.3",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"description": "@absc_company/prettier",
|
|
7
|
-
"
|
|
7
|
+
"files": [
|
|
8
|
+
"dist"
|
|
9
|
+
],
|
|
10
|
+
"main": "dist/index.mjs",
|
|
11
|
+
"types": "dist/index.d.ts",
|
|
8
12
|
"scripts": {
|
|
9
|
-
"
|
|
10
|
-
"build": "
|
|
13
|
+
"prepublishOnly": "pnpm type && pnpm build",
|
|
14
|
+
"build": "tsc --emitDeclarationOnly -p tsconfig.json",
|
|
15
|
+
"type": "tsc --noEmit -p tsconfig.json",
|
|
16
|
+
"format": "prettier --write \"../../**/*.{js,ts,tsx,json,md}\""
|
|
11
17
|
},
|
|
12
18
|
"publishConfig": {
|
|
13
19
|
"access": "public"
|
|
14
20
|
},
|
|
15
21
|
"repository": {
|
|
16
|
-
"
|
|
22
|
+
"type": "git",
|
|
23
|
+
"url": "https://github.com/ABSC-company/synapse-config-package.git"
|
|
17
24
|
},
|
|
18
|
-
"
|
|
25
|
+
"devDependencies": {
|
|
26
|
+
"typescript": "^5.9.2",
|
|
19
27
|
"prettier": "^3.8.1"
|
|
20
28
|
},
|
|
21
29
|
"peerDependencies": {
|
package/.prettierrc.js
DELETED
package/src/index.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import type { Config } from 'prettier';
|
|
2
|
-
|
|
3
|
-
export type Prettier = Config;
|
|
4
|
-
|
|
5
|
-
export const prettier = (params: Prettier = {}) => ({
|
|
6
|
-
printWidth: 100,
|
|
7
|
-
tabWidth: 2,
|
|
8
|
-
singleQuote: true,
|
|
9
|
-
trailingComma: 'none',
|
|
10
|
-
arrowParens: 'always',
|
|
11
|
-
semi: true,
|
|
12
|
-
jsxSingleQuote: true,
|
|
13
|
-
useTabs: false,
|
|
14
|
-
...params
|
|
15
|
-
});
|