Back to Nodegui

NodeGui

README.md

0.74.223.5 KB
Original Source

NodeGui

Build performant, native and cross-platform desktop applications with Node.js and CSS like styling.πŸš€

NodeGUI is powered by Qt6 πŸ’š which makes it CPU and memory efficient as compared to other chromium based solutions like Electron.

If you are looking for React based version, check out: React NodeGUI.

If you are looking for Vue based version, check out: Vue NodeGUI.

If you are looking for Svelte based version, check out: Svelte NodeGUI

Visit https://nodegui.github.io/nodegui for docs.

How does it look?

<div style="display:inline; margin: 0 auto;"> </div> <div style="display:inline; margin: 0 auto;"> </div>

Code Examples

https://github.com/nodegui/examples


Features

  • 🧬 Cross platform. Works on major Linux flavours and Windows. Help is requested to bring it to ARM based MacOS. See issue 1024
  • πŸ“‰ Low CPU and memory footprint. Current CPU stays at 0% on idle and memory usage is under 20MB for a Hello World program.
  • πŸ’… Styling with CSS (includes actual cascading). Also has full support for Flexbox layout (thanks to Yoga).
  • βœ… Complete Nodejs API support (Currently runs on Node v24). Hence has access to all Nodejs compatible NPM modules.
  • πŸŽͺ Native widget event listener support. Supports all events available from Qt / NodeJs.
  • πŸ’Έ Can be used for Commercial applications.
  • πŸ•΅οΈβ€β™‚οΈ Good Devtools support.
  • πŸ“š Good documentation and website.
  • πŸ§™β€β™‚οΈ Good documentation for contributors.
  • πŸ¦ΉπŸ»β€β™€οΈ Good support for dark mode (Thanks to Qt).
  • πŸ…First class Typescript support (Works on regular JS projects too πŸ˜‰).

Getting Started

Installation

To install latest stable release:

npm install @nodegui/nodegui

To install the latest version available on master branch:

npm install https://github.com/nodegui/nodegui/releases/download/v0.0.0-latest-master/nodegui-master.tgz

or a shorter version:

npm i http://master-release.nodegui.org

If the installation fails to download the Qt binaries, a mirror can be used by setting the following environment variable and running the install command again:

sh
QT_LINK_MIRROR=<alternative domain> # eg. QT_LINK_MIRROR=https://qt-mirror.dannhauer.de

npm install @nodegui/nodegui

See FAQs for more details.

Community guides

Talks/Podcasts

Docs for contributing

It is easier than you think, try it

Looking to contribute? If you wish to implement a new widget/add more features and need help understanding the codebase, you can start here: Contributing developer docs.

Please read https://github.com/nodegui/.github/blob/master/CONTRIBUTING.md

Building from source

This section is useful for those wanting to work on NodeGui itself.

Required tooling

NodeGui requires CMake and Compilation Tools as it is a wrapper for a native C++ widget toolkit QT. Detailed instructions here: https://www.sitepoint.com/build-native-desktop-gif-searcher-app-using-nodegui/

TL;DR:

MacOS

brew install cmake
brew install make

Windows

https://cmake.org/download/

Linux (Debian/Ubuntu)

sudo apt-get install pkg-config build-essential
sudo apt-get install cmake make
sudo apt-get install mesa-common-dev libglu1-mesa-dev

Linux (Fedora/RHEL/CentOS)

sudo dnf groupinstall "Development Tools" "Development Libraries"
sudo dnf groupinstall "C Development Tools and Libraries"
sudo dnf install mesa-libGL mesa-libGL-devel

Building

Once you have cloned this git repository, run this to build:

npm install
npm run build

The last step will takes some time to run as it builds the C++ binaries at the core of NodeGui.

Running example programs

A number of small programs to show different parts of the Qt API are in src/examples. They can be run directly with:

npm run qode dist/examples/modelview_1_readonly.js

Updating docs

npm run docs

then followed by:

cd website && GIT_USER=<your_git_username> yarn deploy

Funding

NodeGui is an open source project and requires your support. If you like this project, please consider supporting my work by clicking on the Sponsor button on this Github repository or via Ko-Fi. Alternatively, Issues on NodeGui can be funded by anyone via Issuehunt and the amount will be distributed to respective contributors.

<p> <a href='https://ko-fi.com/E1E510AV9' target='_blank'></a> &nbsp; &nbsp;<a href="https://issuehunt.io/r/nodegui/nodegui"></a> </p>

Special Thanks

Code of Conduct

https://github.com/nodegui/.github/blob/master/CODE_OF_CONDUCT.md

License

MIT

Backers πŸš€

Thanks goes to these wonderful people.

<!-- prettier-ignore --> <table> <tr> <td align="center"><a href="https://github.com/yazla"> <sub><b>Yuriy Yazlovytskyy</b></sub></a></td> <td align="center"><a href="https://github.com/johnsusek"> <sub><b>John Susek</b></sub></a></td> <td align="center"><a href="https://github.com/Spharax"> <sub><b>Marc Dijoux</b></sub></a></td> <td align="center"><a href="https://github.com/Qard"> <sub><b>Stephen Belanger</b></sub></a></td> <td align="center"><a href="https://github.com/irustm"> <sub><b>Rustam</b></sub></a></td> </tr> </table>

Maintainers ✨

People maintaining this project.

<!-- prettier-ignore --> <table> <tr> <td align="center"><a href="https://blog.atulr.com"> <sub><b>Atul R</b></sub></a></td> <td align="center"><a href="https://github.com/sedwards2009"> <sub><b>Simon Edwards</b></sub></a></td> </tr> </table>

Contributors ✨

Thanks goes to these wonderful people (emoji key):

<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section --> <!-- prettier-ignore-start --> <!-- markdownlint-disable --> <table> <tr> <td align="center"><a href="https://lramage.gitlab.io"> <sub><b>Lucas Ramage</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=oxr463" title="Documentation">πŸ“–</a></td> <td align="center"><a href="https://github.com/gamtiq"> <sub><b>Denis Sikuler</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=gamtiq" title="Documentation">πŸ“–</a></td> <td align="center"><a href="https://twitter.com/nahueljo"> <sub><b>Nahuel JosΓ©</b></sub></a> <a href="#question-Naahuel" title="Answering Questions">πŸ’¬</a></td> <td align="center"><a href="https://github.com/kakulgupta"> <sub><b>Kakul Gupta</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=kakulgupta" title="Code">πŸ’»</a></td> <td align="center"><a href="http://rahulgaba.com"> <sub><b>Rahul Gaba</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=rgabs" title="Code">πŸ’»</a></td> <td align="center"><a href="http://uriziel.pl"> <sub><b>PaweΕ‚ Borecki</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=Uriziel01" title="Code">πŸ’»</a></td> <td align="center"><a href="http://marcus-sa.me"> <sub><b>Marcus S. Abildskov</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=marcus-sa" title="Tests">⚠️</a></td> </tr> <tr> <td align="center"><a href="http://www.mad3linux.org"> <sub><b>Átila CamurΓ§a Alves</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=atilacamurca" title="Documentation">πŸ“–</a></td> <td align="center"><a href="http://hibbard.eu"> <sub><b>James Hibbard</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=jameshibbard" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/soonoo"> <sub><b>Soonwoo Hong</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=soonoo" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/illBeRoy"> <sub><b>Roy Sommer</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=illBeRoy" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/paulocoghi"> <sub><b>Paulo Coghi</b></sub></a> <a href="#ideas-paulocoghi" title="Ideas, Planning, & Feedback">πŸ€”</a></td> <td align="center"><a href="https://balthild.com"> <sub><b>Balthild Ires</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=balthild" title="Code">πŸ’»</a></td> <td align="center"><a href="https://dimitarnestorov.com"> <sub><b>Dimitar Nestorov</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=dimitarnestorov" title="Code">πŸ’»</a></td> </tr> <tr> <td align="center"><a href="https://www.greatapes.fi"> <sub><b>Mikko Sairio</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=msairio" title="Code">πŸ’»</a></td> <td align="center"><a href="http://blog.pepf.nl"> <sub><b>Pepijn</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=pepf" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/slidinghotdog"> <sub><b>slidinghotdog</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=slidinghotdog" title="Code">πŸ’»</a></td> <td align="center"><a href="http://www.bundyo.org"> <sub><b>Bundyo (Kamen Bundev)</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=bundyo" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/feng8848"> <sub><b>feng8848</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=feng8848" title="Code">πŸ’»</a></td> <td align="center"><a href="https://karelov.info"> <sub><b>Maksim Karelov</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=Ty3uK" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/mspencer92"> <sub><b>mspencer92</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=mspencer92" title="Code">πŸ’»</a></td> </tr> <tr> <td align="center"><a href="https://github.com/blncd2020"> <sub><b>blncd2020</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=blncd2020" title="Documentation">πŸ“–</a></td> <td align="center"><a href="https://github.com/gluaxspeed"> <sub><b>gluaxspeed</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=gluaxspeed" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/Solant"> <sub><b>Solant</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=Solant" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/shubhamzanwar"> <sub><b>Shubham Zanwar</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=shubhamzanwar" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/Singha360"> <sub><b>Singha360</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=Singha360" title="Code">πŸ’»</a></td> <td align="center"><a href="http://wellenline.com"> <sub><b>Mihkel</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=MihkelBaranov" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/stevo2588"> <sub><b>Stephen A</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=stevo2588" title="Code">πŸ’»</a></td> </tr> <tr> <td align="center"><a href="http://liujunjiang.com"> <sub><b>桁君酱</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=jardenliu" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/agg23"> <sub><b>Adam Gastineau</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=agg23" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/swittk"> <sub><b>swittk</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=swittk" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/craftingmod"> <sub><b>craftingmod</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=craftingmod" title="Code">πŸ’»</a></td> <td align="center"><a href="http://www.m2osw.com"> <sub><b>Doug Barbieri</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=dooglio" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/NeryHenrique"> <sub><b>HENRIQUE DE SOUZA NERY</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=NeryHenrique" title="Code">πŸ’»</a></td> <td align="center"><a href="https://ruslang.xyz"> <sub><b>Ruslan Garifullin</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=ruslang02" title="Code">πŸ’»</a></td> </tr> <tr> <td align="center"><a href="https://github.com/ran-j"> <sub><b>Ranieri</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=ran-j" title="Code">πŸ’»</a> <a href="https://github.com/nodegui/nodegui/commits?author=ran-j" title="Documentation">πŸ“–</a></td> <td align="center"><a href="https://master-technology.com"> <sub><b>Nathanael Anderson</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=NathanaelA" title="Code">πŸ’»</a></td> <td align="center"><a href="https://ubiq.co.za"> <sub><b>Ross</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=rocbear" title="Code">πŸ’»</a> <a href="https://github.com/nodegui/nodegui/commits?author=rocbear" title="Documentation">πŸ“–</a></td> <td align="center"><a href="https://github.com/4h7l"> <sub><b>4h7l</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=4h7l" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/Maks-s"> <sub><b>Maks</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=Maks-s" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/zhb124404"> <sub><b>zhb124404</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=zhb124404" title="Documentation">πŸ“–</a></td> <td align="center"><a href="http://www.apsis.io"> <sub><b>Wyatt Kirby</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=wkirby" title="Code">πŸ’»</a></td> </tr> <tr> <td align="center"><a href="https://stvkoch.github.io."> <sub><b>Steven Koch</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=stvkoch" title="Code">πŸ’»</a></td> <td align="center"><a href="https://github.com/sedwards2009"> <sub><b>Simon Edwards</b></sub></a> <a href="https://github.com/nodegui/nodegui/commits?author=sedwards2009" title="Code">πŸ’»</a></td> </tr> </table> <!-- markdownlint-restore --> <!-- prettier-ignore-end --> <!-- ALL-CONTRIBUTORS-LIST:END -->

This project follows the all-contributors specification. Contributions of any kind welcome!