Skip to content
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

TypeScript templates should have read-only props #58844

Closed
1 task done
hamirmahal opened this issue Nov 23, 2023 · 1 comment · Fixed by #58845
Closed
1 task done

TypeScript templates should have read-only props #58844

hamirmahal opened this issue Nov 23, 2023 · 1 comment · Fixed by #58845
Labels
examples Issue/PR related to examples locked

Comments

@hamirmahal
Copy link
Contributor

hamirmahal commented Nov 23, 2023

Verify canary release

  • I verified that the issue exists in the latest Next.js canary release

Provide environment information

> next info


Operating System:
  Platform: linux
  Arch: x64
  Version: #38~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Thu Nov  2 18:01:13 UTC 2
Binaries:
  Node: 20.9.0
  npm: 10.1.0
  Yarn: N/A
  pnpm: N/A
Relevant Packages:
  next: 14.0.4-canary.12
  eslint-config-next: 14.0.3
  react: 18.2.0
  react-dom: 18.2.0
  typescript: 5.3.2
Next.js Config:
  output: N/A

Which example does this report relate to?

packages/create-next-app/templates/app-tw/ts/app/layout.tsx and packages/create-next-app/templates/app/ts/app/layout.tsx

What browser are you using? (if relevant)

No response

How are you deploying your application? (if relevant)

No response

Describe the Bug

TypeScript templates don't enforce Readonly props.

Expected Behavior

TypeScript templates should enforce Readonly props.

To Reproduce

npx create-next-app@latest # step 1
code packages/create-next-app/templates/app/ts/app/layout.tsx # step 2

Notice that packages/create-next-app/templates/app/ts/app/layout.tsx doesn't enforce Readonly props.

@hamirmahal hamirmahal added the examples Issue/PR related to examples label Nov 23, 2023
styfle added a commit that referenced this issue Jan 5, 2024
- fixes #58844

Co-authored-by: Steven <steven@ceriously.com>
agustints pushed a commit to agustints/next.js that referenced this issue Jan 6, 2024
- fixes vercel#58844

Co-authored-by: Steven <steven@ceriously.com>
Copy link
Contributor

This closed issue has been automatically locked because it had no new activity for 2 weeks. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 20, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
examples Issue/PR related to examples locked
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant