Make the boilerplate more framework agnostic #685
Replies: 2 comments 13 replies
-
I agree with the need to make the boilerplate more framework-agnostic 👍🏽 How can we do it though? The approach we have taken so far has been to use some of the most popular technologies in blockchain/zk projects: Nextjs and React. Looks like a good compromise between the use of modern technology and usability considering the average dev background, but it still doesn't support all devs. In particular, it doesn't support devs without any knowledge of React and NextJS, as you pointed out. We could replace the hooks with functions that can be used with the other frameworks as well, but how can we build components that can be easily re-used in both Vue, Angular, and React? We might consider using Web Components directly, which are framework-agnostic and supported by modern browsers. Another alternative that comes to my mind could be to create a CLI template for each of the main front-end frameworks/libraries. |
Beta Was this translation helpful? Give feedback.
-
To create reusable code, we could use TypeScript code instead of hooks and context (which are React concepts). We could use just components and TypeScript code. Most JS frameworks support TS and the concept of components. For example, this project is using Semaphore with Next.js without hooks and context: https://github.com/bandada-infra/bandada-semaphore-demo Another interesting point is the CSS library (Chakra UI) which is attached to React. We could consider using a framework like |
Beta Was this translation helpful? Give feedback.
-
It would be nice to create the boilerplate in a way that it's as framework-agnostic as possible. Right now it's hard to reproduce the boilerplate if you don't know much about React. There are some developers using other frameworks like
Vue
orAngular
. It may be good for hackers at hackathons to easily reproduce the boilerplate in case they want to use another framework. We could replace React hooks with functions. What do you think?Beta Was this translation helpful? Give feedback.
All reactions