question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Typescript (.ts and .tsx) files have no syntax highlighting when opened in the dev tools Sources tab

See original GitHub issue

Description

I’m developing a website using Typescript. When I open the dev tools, go to the Sources tab and click any .ts or .tsx files, there is no syntax highlighting.

Steps to Reproduce

Requires node/npm to be installed

  1. Run npx create-react-app myappname --typescript
  2. cd myappname
  3. npm start
  4. Open localhost:3000 in brave
  5. Go to DevTools > Sources tab
  6. Open index.tsx or any other ts/tsx file

Actual result:

No syntax highlighting although the debugger still works

image

Expected result:

Syntax highlighting, shown in Chrome

image

Reproduces how often:

Easily reproduced. I’ve never seen it working correctly

Brave version (brave://version info)

Brave 0.67.124 Chromium: 76.0.3809.100 (Official Build) (64-bit)
Revision ed9d447d30203dc5069e540f05079e493fc1c132-refs/branch-heads/3809@{#990}
OS Windows 10 OS Version 1809 (Build 17763.615)

Chrome for comparison:

Google Chrome 76.0.3809.100 (Official Build) (64-bit) (cohort: Stable)
Revision ed9d447d30203dc5069e540f05079e493fc1c132-refs/branch-heads/3809@{#990}
OS Windows 10 OS Version 1809 (Build 17763.615)

Version/Channel Information:

  • Can you reproduce this issue with the current release? Yes
  • Can you reproduce this issue with the beta channel? Not tried
  • Can you reproduce this issue with the dev channel? Yes
  • Can you reproduce this issue with the nightly channel? Not tried

Other Additional Information:

  • Does the issue resolve itself when disabling Brave Shields? No
  • Does the issue resolve itself when disabling Brave Rewards? No
  • Is the issue reproducible on the latest version of Chrome? No

Miscellaneous Information:

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:9
  • Comments:8 (2 by maintainers)

github_iconTop GitHub Comments

3reactions
alexichepuracommented, Dec 3, 2019

@bsclifton thanks for the update! It works for me in nightly after enabling remote debugging and browser restart.

1reaction
bscliftoncommented, Dec 2, 2019

This may be fixed now; with Nightly (and it’ll work its way down through channels), you can enable remote debugging under brave://settings/privacy. When this is enabled, it should fetch sources

@ksbrar @rguillaume @alexichepura and others: can you please try Nightly and confirm it works? (with Remote Debugging enabled?)

Read more comments on GitHub >

github_iconTop Results From Across the Web

In chrome devtools, in all my tsx source files, syntax ...
Any idea how to solve this? Edit: I once solved this by sending content type headers as explained in answer below. But the...
Read more >
TypeScript | IntelliJ IDEA Documentation
IntelliJ IDEA supports developing, running, and debugging TypeScript source code. IntelliJ IDEA recognizes .ts and .tsx files and provides full range of ...
Read more >
TypeScript Programming with Visual Studio Code
TypeScript in Visual Studio Code. TypeScript is a typed superset of JavaScript that compiles to plain JavaScript. It offers classes, modules, and interfaces ......
Read more >
577675 - Can't debug .tsx files when mapped to workspace
1. Debug web application that is NOT mapped into the DevTools workspace. 2. Locate a .tsx file in the Sources pane and open...
Read more >
TSConfig Reference - Docs on every TSConfig option
If a glob pattern doesn't include a file extension, then only files with supported extensions are included (e.g. .ts , .tsx , and...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found