notion-blog-nextjs icon indicating copy to clipboard operation
notion-blog-nextjs copied to clipboard

feat: added typescript support and definitions + some validation

Open KarolNov opened this issue 2 years ago • 4 comments

In order to test out if I can use this repo as boilerplate for my purpose I played around with adding TS + some basic validation. This PR contains results of my work.

KarolNov avatar Mar 13 '22 16:03 KarolNov

Someone is attempting to deploy a commit to a Personal Account owned by @samuelkraft on Vercel.

@samuelkraft first needs to authorize it.

vercel[bot] avatar Mar 13 '22 16:03 vercel[bot]

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/samuelkraft/notion-blog-nextjs/APVboBjYcHZkrQt6PxFYiavfuBkV
✅ Preview: https://notion-blog-nextjs-git-fork-karolnov-feature-0da194-samuelkraft.vercel.app

vercel[bot] avatar Mar 19 '22 15:03 vercel[bot]

Hi @KarolNov, thanks for the PR! Sorry for the slow response here, I've been debating whether adding typescript is a good idea or not for this repo due to added complexity for beginners. I want to keep the repo accessible to new devs and that was the main reason it was not added in the beginning. After giving it some thought I think the benefits outweighs the potential complexity. Would you mind solving the outstanding conflict so I can merge this? Thanks

samuelkraft avatar Apr 06 '22 08:04 samuelkraft

@samuelkraft I guess that make sense and the typings I did are quite complicated (I use different built-in magic methods like Extract) and might be confusing for beginners. I wonder what's the best solution here, but I'm planning to build an open source CMS engine for Notion using Typescript, so I guess once that's published anyone interested in Typescript version can go and find it. If you still think it's worth it I can resolve the conflict when I'll have some spare time.

KarolNov avatar Apr 06 '22 11:04 KarolNov

Closing this to focus on the basic js implementation

samuelkraft avatar Oct 26 '22 15:10 samuelkraft