Skip to content

fix console line number in external browser#503

Merged
andreamah merged 1 commit into
microsoft:mainfrom
toyobayashi:fix-console-line-number
Jun 5, 2023
Merged

fix console line number in external browser#503
andreamah merged 1 commit into
microsoft:mainfrom
toyobayashi:fix-console-line-number

Conversation

@toyobayashi

@toyobayashi toyobayashi commented May 11, 2023

Copy link
Copy Markdown
Contributor

#449

Fixes #508

What createConsoleOverride does is just to call postParentMessage before calling console output methods, but if window.parent === window postParentMessage does nothing, so should we override console only if window.parent !== window? At least this fixes the issue in external browser.

@andreamah andreamah left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch! Thanks for making this change and sorry for the delay! By the way, I created #508 to accompany your PR for verification/tracking purposes.

@andreamah andreamah merged commit c7bafd3 into microsoft:main Jun 5, 2023
@AghayevAydin

Copy link
Copy Markdown

@toyobayashi

Hello I am the Beginner Programming Learner,

After the last update of the VSCODE I do have lots of issues and it requires update again and again. Which solution do you offer me to solve this problem ?

@SammyAbukmeil

Copy link
Copy Markdown

This seems to be an issue still, I'm getting ___vscode_livepreview_injected_script:141 for all my console logs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Injected code unnecessarily clobbers external browser console.logs

5 participants