Skip to content

Commit 174bcb4

Browse files
suhdonghwiSuh Donghwi
andauthored
Replace manual resolution algorithm with oxc_resolver (#3)
* deps: add oxc_resolver to stylex-path-resolver dependencies * refactor: simplify file path resolution using oxc_resolver * refactor: remove unused functions and clean up imports in file system and resolvers * fix(resolvers): add condition names to resolve options * fix: reorder "require" and "import" fields in package.json for stylex-lib-dist-exports-commonjs-esm * chore: replace stylex-lib-pnpm and @stylex/lib-exports packages with symlinks * test: remove spec incompliant test for resolving organisation package * refactor: replace local file path resolution logic with oxc_resolver * refactor: remove unused package_json_seen parameter * refactor: clean up imports by removing unused HashMap references * refactor: remove unused functions and clean up imports in file system and resolvers * refactor: remove unused Regex pattern and clean up imports in path resolver * refactor: resolve_file_path logic simplifying * refactor: simplify resolve_file_path function by removing root_path parameter * feat: turn on oxc_resolver yarn_pnp feature flag * chore: clippy fix & fmt --------- Co-authored-by: Suh Donghwi <[email protected]>
1 parent 5dccc8d commit 174bcb4

File tree

22 files changed

+431
-1936
lines changed

22 files changed

+431
-1936
lines changed

Cargo.lock

Lines changed: 305 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/stylex-path-resolver/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,4 @@ indexmap.workspace = true
3030

3131
package-json = "0.5.0"
3232
pathdiff = { version = "0.2.3" }
33+
oxc_resolver = { version = "11.8.3", features = ["yarn_pnp"] }

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-dist-pnpm

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-dist-pnpm/dist/index.js

Whitespace-only changes.

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-dist-pnpm/dist/tokens.stylex.js

Whitespace-only changes.

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-dist-pnpm/package.json

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

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-pnpm

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-pnpm/dist/colors.stylex.js

Whitespace-only changes.

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-pnpm/dist/index.js

Whitespace-only changes.

crates/stylex-path-resolver/fixtures/application-pnpm/node_modules/@stylex/lib-exports-pnpm/dist/tokens.stylex.js

Whitespace-only changes.

0 commit comments

Comments
 (0)