@jesscss/style-resolver 2.0.0-alpha.6 → 2.0.0-alpha.7

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 (2) hide show
  1. package/package.json +2 -3
  2. package/lib/index.d.cts +0 -35
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jesscss/style-resolver",
3
- "version": "2.0.0-alpha.6",
3
+ "version": "2.0.0-alpha.7",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
@@ -10,7 +10,6 @@
10
10
  "exports": {
11
11
  ".": {
12
12
  "types": "./lib/index.d.ts",
13
- "source": "./src/index.ts",
14
13
  "import": "./lib/index.js",
15
14
  "require": "./lib/index.cjs"
16
15
  }
@@ -25,7 +24,7 @@
25
24
  "module": "lib/index.js",
26
25
  "scripts": {
27
26
  "build": "pnpm compile",
28
- "compile": "tsdown --tsconfig tsconfig.build.json && tsc -p tsconfig.build.json --emitDeclarationOnly",
27
+ "compile": "tsdown --tsconfig tsconfig.build.json --no-dts && tsc -p tsconfig.build.json --emitDeclarationOnly --noCheck",
29
28
  "test": "vitest --watch=false",
30
29
  "lint": "eslint '**/*.{js,ts}'"
31
30
  }
package/lib/index.d.cts DELETED
@@ -1,35 +0,0 @@
1
- //#region src/index.d.ts
2
- type StyleLang = 'css' | 'less' | 'scss' | 'jess';
3
- type FsLike = {
4
- exists(filePath: string): boolean;
5
- };
6
- type StylesConfig = {
7
- /** Project root; used as an optional search base. */rootDir?: string; /** Less-style include paths. */
8
- includePaths?: string[]; /** SCSS-style load paths. */
9
- loadPaths?: string[];
10
- };
11
- type ImportStatement = {
12
- lang: StyleLang;
13
- specifier: string;
14
- options?: string[];
15
- specifierRange: {
16
- startOffset: number;
17
- endOffset: number;
18
- };
19
- };
20
- type ResolveResult = {
21
- filePath: string;
22
- resolvedBy: 'exact' | 'extension' | 'partial' | 'index' | 'loadPath';
23
- };
24
- type ResolveImportOptions = {
25
- lang: StyleLang;
26
- fromFilePath: string;
27
- specifier: string;
28
- config?: StylesConfig;
29
- };
30
- declare function extractImports(sourceText: string, lang: StyleLang): ImportStatement[];
31
- declare function expandLessImportCandidates(importPath: string): string[];
32
- declare function expandScssImportCandidates(importPath: string): string[];
33
- declare function resolveImport(fs: FsLike, opts: ResolveImportOptions): ResolveResult | null;
34
- //#endregion
35
- export { FsLike, ImportStatement, ResolveImportOptions, ResolveResult, StyleLang, StylesConfig, expandLessImportCandidates, expandScssImportCandidates, extractImports, resolveImport };