-
Notifications
You must be signed in to change notification settings - Fork 8
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
Improve DX for shared TS codebase #4
Conversation
Thanks! Although this PR doesn’t address what we discussed in the issue, which is to recompile tsconfig paths. We should not assume src/shared is significant to TS users. |
The code section is only recompiling typescript handlers if the file ends with |
It will work for some, but this is more along the lines of the Architecty way, not the TypeScripty way. The approach we've tried to take for this plugin was to build it in the most TypeScripty way possible. In the example app we demonstrate using both If we are going to look at |
@ryanblock I've updated the logic to use tsconfig.json |
src/shared
return | ||
} | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good otherwise, although we still need tests!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ryanblock I've updated the logic to:
- take care of windows path
- take care of non TS/TSX paths alias
|
||
let enPath = join(mock, 'defaults', 'src', 'shared', 'locales', 'en.ts') | ||
let oldEn = readFileSync(enPath) | ||
writeFileSync(enPath, 'export default "bar";\n') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ryanblock Is there a way to start the sandbox with watcher? It seems like we can only start sandbox with watcher using CLI...
Thank you for helping out! ✨
We really appreciate your commitment to improving Architect
To maintain a high standard of quality in our releases, before merging every pull request we ask that you've completed the following:
master
npm it
from the repo root)readme.md
, help docs, inline docs & comments, etc.)changelog.md
Please also be sure to completed the CLA (if you haven't already).
Learn more about contributing to Architect here.
Thanks again!