babel-plugin-jsx
jsx-vue2
babel-plugin-jsx | jsx-vue2 | |
---|---|---|
6 | 3 | |
1,686 | 1,463 | |
0.9% | 0.8% | |
8.3 | 0.0 | |
7 days ago | 10 months ago | |
TypeScript | JavaScript | |
MIT License | - |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
babel-plugin-jsx
-
Can you give me an idea on how to implement this in vue?
It's also possible to use JSX, as OP's example, using https://github.com/vuejs/babel-plugin-jsx
-
State of JSX in JavaScript Frameworks
Even though templates (or let’s say, SFC) is the dominant way to author Vue components, decent JSX support is also provided for both Vue 2 and Vue 3.
-
The self-fulfilling prophecy of React
I agree - I think JSX does what templating languages have been trying to do for years.
That being said, solid is hardly the only one out there competing that can use JSX:
- https://github.com/vuejs/babel-plugin-jsx
- https://mithril.js.org/jsx.html
- https://preactjs.com/guide/v10/getting-started#setting-up-js...
-
Have been using Vue.js for a while but decided to learn React because of how popular and demanded it is. Not trying to bash React but I can't get over the funkyness of JSX and a couple of other aspects. Everything seems more complex and cumbersome than how it's done in Vue.js. Am I just biased?
Apologies, my link above was the incorrect bookmark... that was for Vue 2. Here is the correct link for vue3: https://github.com/vuejs/jsx-next
-
Vue with TSX - the perfect duo!?
In a nutshell, you once again have to add jsx: “preserve” to your tsconfig.json and do some changes in your Babel config (it’s a plugin this time):
-
Has anyone used JSX with Vue 3?
This exists and works fine - I am using TSX and getting type checking around props etc etc, all the things you'd expect.
jsx-vue2
-
State of JSX in JavaScript Frameworks
Even though templates (or let’s say, SFC) is the dominant way to author Vue components, decent JSX support is also provided for both Vue 2 and Vue 3.
-
Have been using Vue.js for a while but decided to learn React because of how popular and demanded it is. Not trying to bash React but I can't get over the funkyness of JSX and a couple of other aspects. Everything seems more complex and cumbersome than how it's done in Vue.js. Am I just biased?
You can and have been able to use jsx with Vue for quite some time: https://github.com/vuejs/jsx
-
Vue with TSX - the perfect duo!?
Let’s start with pure JSX. A quick search on Vue 2 docs brings the following results: There’s certainly not a lot of it, but potentially that’s all we need? The link redirects us to a GitHub README, detailing the installation of the required Babel plugin and the general usage of JSX with other Vue features.
What are some alternatives?
vite - Next generation frontend tooling. It's fast!
htm - Hyperscript Tagged Markup: JSX alternative using standard tagged templates, with compiler support.
Immer - Create the next immutable state by mutating the current one
valtio - 💊 Valtio makes proxy-state simple for React and Vanilla
immutable-js - Immutable persistent data collections for Javascript which increase efficiency and simplicity.
volar - ⚡ Explore high-performance tooling for Vue [Moved to: https://github.com/vuejs/language-tools]
parcel - The zero configuration build tool for the web. 📦🚀
reactivue - 🙊 Use Vue Composition API in React components
language-tools - The Svelte Language Server, and official extensions which use it