-
Notifications
You must be signed in to change notification settings - Fork 1k
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(cli): Option to inline JS source maps during sync #5843
Conversation
cli/src/tasks/sourcemaps.ts
Outdated
import type { Config } from '../definitions'; | ||
import { logger } from '../log'; | ||
|
||
function findJSAssetsDir(buildDir: string): string { |
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.
JS files could be any folder. Im not sure you would want to hard code this for React and Vue.
cli/src/tasks/sourcemaps.ts
Outdated
|
||
function findJSAssetsDir(buildDir: string): string { | ||
const reactJSDir = '/static/js'; | ||
const vueJSDir = '/js'; |
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.
Path.join is required for folder separators which will change based on platform (eg on windows its \ rather than /)
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.
Im a little concerned you'll miss JS files if you hardcode a subfolder in the output directory.
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.
Looks good to me.
Adds an option to the
sync
command ,--inline
, which will, after syncing, inline all JS source maps for easier debugging on mobile devices.