Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(codemod-rewrite-module-specifiers-to-full-paths): implement project #2

Merged
merged 31 commits into from
Sep 15, 2024
Merged
Changes from 1 commit
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
b3407ab
draft
pkerschbaum Sep 15, 2024
162fd27
draft
pkerschbaum Sep 15, 2024
5a43200
draft
pkerschbaum Sep 15, 2024
b8933f1
test: use vitest
pkerschbaum Sep 15, 2024
d0f04b3
failling testcase
pkerschbaum Sep 15, 2024
04b18d7
fix: extension
pkerschbaum Sep 15, 2024
468399c
refactor(codemod-apply-full-paths-to-imports): improve
pkerschbaum Sep 15, 2024
2d4f8f5
test(codemod-apply-full-paths-to-imports): add test cases
pkerschbaum Sep 15, 2024
d119361
refactor(codemod-apply-full-paths-to-imports): subfolder for transformer
pkerschbaum Sep 15, 2024
27e38d1
feat(codemod-apply-full-paths-to-imports): use `jscodeshift` to chang…
pkerschbaum Sep 15, 2024
11621ff
refactor(codemod-apply-full-paths-to-imports): improve
pkerschbaum Sep 15, 2024
c0f099d
chore: rename to `codemod-rewrite-module-specifiers-to-full-paths`
pkerschbaum Sep 15, 2024
fa6340d
refactor: extract `load-typescript-program`
pkerschbaum Sep 15, 2024
eacb550
refactor: improve
pkerschbaum Sep 15, 2024
896c219
fix(codemod-rewrite-module-specifiers-to-full-paths): do not replace …
pkerschbaum Sep 15, 2024
a91206f
chore: rename
pkerschbaum Sep 15, 2024
508fb88
feat(codemod-rewrite-module-specifiers-to-full-paths): register `code…
pkerschbaum Sep 15, 2024
f98a4ed
fix: relative and absolute paths
pkerschbaum Sep 15, 2024
b7e2a5e
fix: resolve TS extensions to JS extensions explicitely
pkerschbaum Sep 15, 2024
781527a
fix: keep .js extensions
pkerschbaum Sep 15, 2024
ba527db
feat: throw error if tsconfig cannot be found
pkerschbaum Sep 15, 2024
60cae60
feat(@pkerschbaum/runtime-extensions-node): implement project, load `…
pkerschbaum Sep 15, 2024
4f23f32
feat(codemod-rewrite-module-specifiers-to-full-paths): load `@pkersch…
pkerschbaum Sep 15, 2024
a655f29
fix: resolved `compilerOptions.baseUrl` is actually already resolved,…
pkerschbaum Sep 15, 2024
d991576
fix: apply more sophisticated extension mapping as we need to map e.g…
pkerschbaum Sep 15, 2024
8fc3721
fix: do not throw if module cannot be resolved to allow e.g. ".png" m…
pkerschbaum Sep 15, 2024
b634d9b
fixup
pkerschbaum Sep 15, 2024
2294bc7
fix: apply more sophisticated ext mapping already on TS `resolvedFile…
pkerschbaum Sep 15, 2024
970bbbe
test: add more test cases
pkerschbaum Sep 15, 2024
6bd7afc
chore: remove unused project
pkerschbaum Sep 15, 2024
b1fa24a
chore: rename things
pkerschbaum Sep 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
feat(codemod-rewrite-module-specifiers-to-full-paths): load `@pkersch…
…baum/runtime-extensions-node`
pkerschbaum committed Sep 15, 2024
commit 4f23f3224588b8ac6e6946c1b2c811a3a95ee78c
Original file line number Diff line number Diff line change
@@ -42,6 +42,8 @@
"dependencies": {
"@commander-js/extra-typings": "^12.1.0",
"@pkerschbaum/commons-ecma": "workspace:*",
"@pkerschbaum/commons-node": "workspace:*",
"@pkerschbaum/runtime-extensions-node": "workspace:*",
"commander": "^12.1.0",
"jscodeshift": "^17.0.0",
"p-limit": "^6.1.0",
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import '@pkerschbaum/runtime-extensions-node';

import * as commander from '@commander-js/extra-typings';
import fs from 'node:fs';