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.

with-typescript-eslint-jest creates pages/api/hello.tsx

See original GitHub issue

Bug report

with-typescript-eslint-jest creates pages/api/hello.tsx instead of pages/api/hello.ts

To Reproduce

  1. npx create-next-app --example with-typescript-eslint-jest with-typescript-eslint-jest-app
  2. page/api/ has hello.tsx instead of hello.ts

Expected behavior

Expected a .ts file and not a .tsx file for API.

Screenshots

N/A

System information

  • OS: Ubuntu 20.04
  • Browser: N/A
  • Version of Next.js: 9.5.3
  • Version of Node.js: 14.9.0

Additional context

This is easy for me to fix. For new or less experienced users this might be confusing and misleading.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
piotrzaryckicommented, Sep 7, 2020

Hi, can i take this one? 😃

1reaction
timneutkenscommented, Sep 7, 2020

Both are fine really, but feel free to send a PR.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Node.js (Express) with TypeScript, Eslint, Jest, Prettier and ...
Installing Jest is easy, run the command below and you will install Jest including its type definition and Typescript Jest runner:.
Read more >
Using eslint with typescript - Unable to resolve path to module
You can set the ESLint module import resolution by adding this snippet to your .eslintrc.json configuration file:
Read more >
Configuring Jest
It is recommended to define the configuration in a dedicated JavaScript, TypeScript or JSON file. The file will be discovered automatically, ...
Read more >
Setting up vite, React, TypeScript, eslint, vitest, testing-library ...
In this video I show how to setup a react app with vite, typescript, eslint, vitest, testing-library and react-router.
Read more >
React + TypeScript + ESLint + Prettier Full Setup
Hello amazing developer ‍ , before digging into this topic let me give you a small introduction and so instructions.
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