Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/anthonydmays/frameworkless-react

A demo using React without a framework in pure JS
https://github.com/anthonydmays/frameworkless-react

html javascript react reactjs

Last synced: 18 days ago
JSON representation

A demo using React without a framework in pure JS

Awesome Lists containing this project

README

        

[![pages-build-deployment](https://github.com/anthonydmays/frameworkless-react/actions/workflows/pages/pages-build-deployment/badge.svg)](https://github.com/anthonydmays/frameworkless-react/actions/workflows/pages/pages-build-deployment)

# Framework-less React Demo

## Author

Anthony D. Mays (@anthonydmays) - [YouTube](https://youtube.com/@anthonydmays) | [Twitter](https://twitter.com/anthonydmays) | [LinkedIn](https://linkedin.com/in/anthonydmays) | [Github](https://github.com/anthonydmays)

## Purpose

This demo shows how to import the React library from NPM via the JSPM server and build components without any compilation or framework. Though not ideal for production apps, it can be useful for rapid prototyping or for enhancing simple static sites that can be easily deployed.

Learn how I did it by checking out my short [on YouTube](https://youtube.com/shorts/G2-HIgIUbhY?feature=share).

## Tools used

* [React](https://react.dev)
* [HTM](https://github.com/developit/htm)
* [lit-html (VS Code extension)](https://marketplace.visualstudio.com/items?itemName=bierner.lit-html)
* [JSPM Generator](https://generator.jspm.io/)
* [Tailwind CSS](https://tailwindcss.com/)

## TODO

- [ ] Add example component with embedded CSS stylesheet
- [ ] Experiment with Shadow DOM

## More Resources

* [Using React without JSX == no build (dev.to)](https://dev.to/dperrymorrow/using-react-without-jsx-no-build-14gg) by David Morrow
* [React, JSX, ES module imports (dynamic too) in browser without Webpack (Medium)](https://medium.com/@chrislewisdev/react-without-npm-babel-or-webpack-1e9a6049714) by Kirill Konshin