Home

Awesome

Paw

A low-code, vdom-free hyperscript framework.

bundlejs License: MIT

Demo

❤️ Features

💻 Usage

Copy the boilerplate folder to your machine and run the command inside it.

python3 -m http.server

This is what you will get!

The folder contains 3 files

The demo app uses index.html as the home page and app.js as the router.

All routes were distributed across several modules within the views folder.

It can be an excellent practical reference on how to use Paw and how to organize the code.

🎯 Goals

📢 Motivation

Why are JS frameworks bad?

Frameworks like:

suffer from the same problem.

We can argue that vDom is slow so svelte solves the problem by compiling javascript in the build steps.

We can argue that the frameworks are heavy and svelte solves the problem again, qwik only loads js on demand, and hyperapp is too minimalistic.

We can argue that build steps are unecessary complication and hyperapp is the clear winner here.

But this is getting away from the central problem with these approaches, which they ALL suffer from.

The problem is that frameworks need to control JavaScript centrally in the elements and/or components that are used.

This implies that the code of a library external to the framework must be rewritten.

See for example the number of existing Bootstrap javascript implementations:

These projects exist for the reason that vDom and the implementation of a component library conflict.

If you need a less popular external library and/or use a framework with a smaller community, you will have to reimplement javascript or wait for someone to do it with all the difficulties and bugs involved.

Why web components are bad?

Libraries like Shoelace allow you to use reactive components within these frameworks without having to be reimplemented.

The problem is data exchange, two way data binding needs to be implemented individually for each framework.

Components written in HTML do not have the good parts of these vDom frameworks that allow you to easily pass objects, arrays and functions to them, greatly limiting their capacity and making the API difficult.

Why I build this project?

I wanted to have components with all the capabilities of javascript frameworks (passing objects, arrays and functions).

And have a simplified interface to access work done in libraries like Bootstrap without having to reimplement javascript.

The fact that using hyperscript allows you to encapsulate the logic of the components in small modules that make the weight of the vDom unnecessary.

I didn't want to have to deal with the complications of build steps.

And I wanted the libraries I used to only be loaded when called (using es6 modules or dynamically adding the script to the page).

And to achieve good SEO, produce an SSR home page with the customization options that exist in the open source world.

I didn't find anything on github or google that went this route, so I created it.

🔧 TODO

🤝 Contributing

It's a very simple project. Any contribution, any feedback is greatly appreciated.

⭐ Support

If this project was useful to you, consider giving it a star on github, it's a way to increase evidence and attract more contributors.

🙏 Acknowledgment

This work would not be possible if it were not for these related projects:

A huge thank you to all the people who contributed to these projects.