converted the old tailwind css example to typescript #32808
converted the old tailwind css example to typescript #32808kodiakhq[bot] merged 4 commits intovercel:canaryfrom
Conversation
balazsorban44
left a comment
There was a problem hiding this comment.
Thanks.
I left some comments.
Could you also please run npx prettier --write ./examples/with-tailwindcss to fix the lint errors and commit the changes?
Yes sure will be doing that |
|
Please let's focus this PR on the tailwind example. If you would like to convert other examples to TypeScript, you are welcome to do so, but open a separate PR instead. It makes it easier to track down changes in the future. Thank you. |
Sure will we doing that, and from on I will be doing this in a systemic way. |
|
@leerob I have reverted all the unrelated files |
There was a problem hiding this comment.
Please remove all the changes, except in the folder: examples/with-tailwindcss as requested here #32808 (comment) (I could have been more explicit)
There are still changes within examples/progressive-web-app
bc41514 to
ddd1678
Compare
I have reverted the commit , but it is still showing the same changes in file, can you please guide me , to performer this task. |
8902b2d to
5585bf2
Compare
|
@balazsorban44 I have reverted all the unrelated files . |
…o-example * 'canary' of github.com:vercel/next.js: [chore] Update `deta` version in examples (vercel#30204) fix: typescript example supporting strict w/ version >= 4.4 (vercel#33042) Avoid page double render with emotion vanilla (vercel#30541) converted the old tailwind css example to typescript (vercel#32808) fix(examples/cms-contentful): add correct Content-Type + missing closing tag for html (vercel#30321) Ensure NODE_ENV is not inlined for next/jest (vercel#33032) Rename api in with-redis example (vercel#33016) Remove unused turbo remote cache env vars (vercel#33030) v12.0.8-canary.17 Re-enable turbo caching for swc build jobs (vercel#32617) feat(cli): introduce `next info` CLI command (vercel#32972) fix(examples): add missing dependencies wo (vercel#32977) Updated wrong link to example of gtag init in measuring-performance.md (vercel#32974) v12.0.8-canary.16 Revert "Reduce install size for linux glibc/musl (vercel#32850)" (vercel#32973) Ensure middleware is output in standalone mode (vercel#32967) v12.0.8-canary.15 Reduce install size for linux glibc/musl (vercel#32850) Fixes issue with makeStylesheetInert (vercel#32027) Ensure setImmediate and punycode are polyfilled (vercel#32768)
| @@ -0,0 +1,3 @@ | |||
| { | |||
| "extends": "next/core-web-vitals" | |||
There was a problem hiding this comment.
I don't think we should include ESLint - while it is helpful, I think this example should be as simple as possible - just Next.js and Tailwind.
| @@ -1,3 +1,11 @@ | |||
| <p align="center"> | |||
|
|
|||
| <img src="https://res.cloudinary.com/ddcg0rzlo/image/upload/v1640340715/nextjs-tailwind-typescript-banner_vslgq4.png" alt="Next.js TypeScript Starter"> | |||
There was a problem hiding this comment.
Could we remove this image please?
|
example is typescript now? how do i start a nextjs tailwind without typescript ? npx create-next-app --example with-tailwindcss with-tailwindcss-app |
|
Yes, the example is now using TypeScript. If you would prefer not to use it, you can remove the TS configuration (it's a few files/lines). |
|
Thanks for the reply dude, I’m new at programming I figured it out just a few changes a little clean up
Thanks again dude
Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows
From: Lee ***@***.***>
Sent: 07 January 2022 22:44
To: ***@***.***>
Cc: ***@***.***>; ***@***.***>
Subject: Re: [vercel/next.js] converted the old tailwind css example to typescript (PR #32808)
Yes, the example is now using TypeScript. If you would prefer not to use it, you can remove the TS configuration (it's a few files/lines).
—
Reply to this email directly, view it on GitHub<#32808 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AUTKX5DJEOTAG7TNYNVVHVLUU5UGXANCNFSM5KXMH6DQ>.
Triage notifications on the go with GitHub Mobile for iOS<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you commented.Message ID: ***@***.***>
|
|
Why was the JavaScript example changed to TypeScript? I think the default example should be using JavaScript. I refer this in my next app guides and it can be complicated for the readers to manually convert TS to JS. We can do something like |
|
@ahmadbilaldev totally agrees with you here. There should also be a JavaScript-based template available for the Next.js TailwindCSS example. @balazsorban44 can we do something about it? |
|
The way forward is that we are going to focus on TypeScript and prefer it over JS in examples, as it provides more safety even for beginner developers, and is being more and more widely adopted. We are discussing alternatives like a |
Bug
fixes #numbercontributing.mdFeature
fixes #numbercontributing.mdDocumentation / Examples
yarn lint