Please describe your proposed solution.
PureScript is a language very similar to Haskell which compiles to JavaScript, and is widely used to build frontend user interfaces of Cardano DApps.
Vue.js is an approachable, performant and versatile framework for building web user interfaces. It features the single file component format, which augments standard HTML with template syntax and custom script tags.
My proposal is to build an embedded domain specific language to bridge Vue Composition API to PureScript language inside Vue single file components. With this funding I would focus on implementing the proof of concept and release the final improved version.
Please describe how your proposed solution will address the Challenge that you have submitted it in.
- Vue is very popular among less experienced web developers: according State of JavaScript 2021 and Stackoverflow 2020, Vue is the third most used framework, the second with more awareness and desire.
- Vue is already integrated with Vite, Vue-cli, Webpack, Rollup and many other frontend tools. Having a compiler step built into the Vue compiler will seamlessly expose the PureScript language to all these tools.
- PureScript is the closest language to the Haskell language, having a way to step from JavaScript world to the Haskell world is currently the most difficult challange in the Cardano developer ecosystem.
- Vue has an appealing template syntax targeting web developers.
These findings corroborate the challange solution requeriments, because it invites web developers of these frameworks to be familiar with Haskell. When this developer choose for a blockchain technology, he/she will try to find a familiar developer ecosystem, and PureScript will be the bridge to bring web developers to Cardano ecosystem.
What are the main risks that could prevent you from delivering the project successfully and please explain how you will mitigate each risk?
- Not having an easy way to inject PureScript code into the Vue compiler setup hook. It would be necessary to rethink the domain specific language approach or change the project scope to extend the purescript or vue compiler with specific features, requiring more time and funding.
- I'm trying to anticipate this problem by building a proof of concept with a minimal example of composition API integration.
- Actually making the development experience worse, because of extensive usage of specific domain language and subtitle changes from the default PureScript/Vue behavior.
- I will try to reuse as much of the Vue APIs as possible and clearly document each behavior change on the PureScript side.
- In fact, making the development experience worse, due to using a package manager for another language (PureScript).
- I added in roadmap a new feature to install PureScript packages from the JavaScript package manager, this way we can mitigate this problem.
- Not reaching the targeted audience
- I'll list the project on awesome lists, divulgate on community channels (discord and forums). I'll also list the project on Cardano developer docs.
- I have made a test on PureScript community and it already engaged some devs, we have 13 stars on the GitHub repo having only with the idea of the project.