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.

Allow custom extensions (.ts .tsx .jsx)

See original GitHub issue

Pretty interesting proposal here: https://github.com/zeit/next.js/pull/2250/files#diff-0f2f34c098f5954f99483c9bd61e439dR51. We could reutilize this as a custom key in next.config.js to allow any file extension. Which also resolves the .jsx extension support 👍 talked about it with @arunoda 👌

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:2
  • Comments:31 (7 by maintainers)

github_iconTop GitHub Comments

19reactions
D1nocommented, Aug 29, 2017

Hey @arunoda @timneutkens @nkzawa @rauchg , a friendly reminder that there is on open PR (https://github.com/zeit/next.js/pull/2699) to close this “help wanted” labeled ticket. Though it is labeled also as “nice to have”, not being able to use TypeScript prevents my company and two other open source projects to switch over to next.js.

It may be that you guys are not in a particular need for TypeScript, but searching this repository for typescript revels 31 related tickets alone. Excluding any jsx and extension tickets. image

Me, including a broad band of the developer community, right up refuses to implement un-typed code. Especially if it is run universally on two or more infrastructures (server, browser, ios, android etc). image

So I urge you guys to promote this ticket up in your priority chain and take a look at the sitting contribution. A few people have offered help already. Leveling off ecmascript variants (jsx, tsx, cl, etc.) is simply not a gimic. After that, next.js will defiantly become a go-to SSR solution. image

Thank you for the great work you have put into this project. I am excited what comes next to next.js — all that beyond this corner issue.

Best Dino

11reactions
pie6kcommented, Oct 26, 2017

Any update?

Read more comments on GitHub >

github_iconTop Results From Across the Web

80 - Stack Overflow
JSX not allowed in files with extension '.tsx'eslint(react/jsx-filename-extension) · Ask Question. Asked 3 years, 8 months ago.
Read more >
Documentation - JSX - TypeScript
Name your files with a .tsx extension; Enable the jsx option ... (e.g. a div or span in a DOM environment) or to...
Read more >
When To Use .ts And .tsx File Extensions - Andrew Hansen
When To Use .ts And .tsx File Extensions ... The only alternative was to use the non-JSX syntax for React: React.createElement .
Read more >
Custom Page Extensions - next.config.js
Extend the default page extensions used by Next.js when resolving pages in the pages directory.
Read more >
ts-node - npm
In many cases, setting NODE_OPTIONS will enable ts-node within other ... by registering hooks for .ts , .tsx , .js , and/or .jsx...
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