Git Product home page Git Product logo

nodegui / nodegui Goto Github PK

View Code? Open in Web Editor NEW
8.7K 94.0 286.0 92.66 MB

A library for building cross-platform native desktop applications with Node.js and CSS πŸš€. React NodeGui : https://react.nodegui.org and Vue NodeGui: https://vue.nodegui.org

Home Page: http://docs.nodegui.org

License: MIT License

C++ 65.25% TypeScript 27.04% CMake 1.10% C 4.50% JavaScript 1.98% CSS 0.12%
nodejs desktop openlibrary qt cross-platform javascript gui

nodegui's Introduction

NodeGui

All Contributors JS Party #96 Build and Test status Discuss on GitHub

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.

logo

How does it look?

demo_linux demo_win demo_mac
kitchendemo_macdemo_win

Code Examples

https://github.com/nodegui/examples


Features

  • 🧬 Cross platform. Works on major Linux flavours, Windows, and MacOS.
  • πŸ“‰ 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 v16.x - and is easily upgradable). 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:

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.

Using your own custom Qt installation (Optional)

Compiling Qt from source

You will need to download and install Qt from source since there are no binaries from Qt for M1 yet.

(https://www.reddit.com/r/QtFramework/comments/ll58wg/how_to_build_qt_creator_for_macos_arm64_a_guide/)

git clone git://code.qt.io/qt/qt5.git qt6
cd qt6
git checkout 6.6

./init-repository --module-subset=essential -f
git submodule init qtsvg
git submodule update qtsvg

cd ..
mkdir qt6-6.6-macOS-release
cd qt6-6.6-macOS-release

../qt6/configure -release QMAKE_APPLE_DEVICE_ARCHS=arm64 -opensource -confirm-license -nomake examples -nomake tests -skip qt3d -skip webengine -skip qtactiveqt -skip qtcanvas3d  -skip qtdeclarative -skip qtdatavis3d -skip qtdoc -skip qtgamepad -skip qtcharts -skip qtgraphicaleffects -skip qtlocation  -skip qtpurchasing -skip qtquickcontrols -skip qtquickcontrols2 -skip qtremoteobjects -skip qtscxml -skip qtsensors -skip qtserialbus -skip qtserialport -skip qtspeech -skip qtvirtualkeyboard -skip qtscript

make -j15

make install

This should install Qt into something like this /usr/local/Qt-6.6.0 (your directory can change. This will be displayed when running make)

Pointing nodegui to use your custom Qt installation

Now just set export QT_INSTALL_DIR=<your qt path> . In the above example it would look something like this export QT_INSTALL_DIR=/usr/local/Qt-6.6.0. Add this in your .zshrc or .bashrc so that you dont need to repeat this process again.

Now just rm -rf node_modules and do npm install again.

The logs should say something like CustomQt detected at <your qt path>. Hence, skipping Mini Qt installation.

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.

Buy Me a Coffee at ko-fi.com Β  Β issuehunt

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.

Yuriy Yazlovytskyy
Yuriy Yazlovytskyy
John Susek
John Susek
Marc Dijoux
Marc Dijoux
Stephen Belanger
Stephen Belanger
Rustam
Rustam

Maintainers ✨

People maintaining this project.

Atul R
Atul R
Simon Edwards
Simon Edwards

Contributors ✨

Thanks goes to these wonderful people (emoji key):


Lucas Ramage

πŸ“–

Denis Sikuler

πŸ“–

Nahuel JosΓ©

πŸ’¬

Kakul Gupta

πŸ’»

Rahul Gaba

πŸ’»

PaweΕ‚ Borecki

πŸ’»

Marcus S. Abildskov

⚠️

Átila Camurça Alves

πŸ“–

James Hibbard

πŸ’»

Soonwoo Hong

πŸ’»

Roy Sommer

πŸ’»

Paulo Coghi

πŸ€”

Balthild Ires

πŸ’»

Dimitar Nestorov

πŸ’»

Mikko Sairio

πŸ’»

Pepijn

πŸ’»

slidinghotdog

πŸ’»

Bundyo (Kamen Bundev)

πŸ’»

feng8848

πŸ’»

Maksim Karelov

πŸ’»

mspencer92

πŸ’»

blncd2020

πŸ“–

gluaxspeed

πŸ’»

Solant

πŸ’»

Shubham Zanwar

πŸ’»

Singha360

πŸ’»

Mihkel

πŸ’»

Stephen A

πŸ’»

桁君酱

πŸ’»

Adam Gastineau

πŸ’»

swittk

πŸ’»

craftingmod

πŸ’»

Doug Barbieri

πŸ’»

HENRIQUE DE SOUZA NERY

πŸ’»

Ruslan Garifullin

πŸ’»

Ranieri

πŸ’» πŸ“–

Nathanael Anderson

πŸ’»

Ross

πŸ’» πŸ“–

4h7l

πŸ’»

Maks

πŸ’»

zhb124404

πŸ“–

Wyatt Kirby

πŸ’»

Steven Koch

πŸ’»

Simon Edwards

πŸ’»

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

nodegui's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nodegui's Issues

Fails to build on Ubuntu 16.04 (libc < GLIBC_2.25 or gcc < 7)

On Ubuntu it gives out this error, could not solve it with #16

> @nodegui/[email protected] install /home/vince/test/nodegui/node_modules/@nodegui/nodegui
> npm -v

6.10.2

> @nodegui/[email protected] postinstall /home/vince/test/nodegui/node_modules/@nodegui/qode
> node install.js

Local Qode 1.0.2 archive doesnt exists... Copying Qode from cache...
Copying Qode from cache failed...  Error: ENOENT: no such file or directory, stat '/home/vince/.cache/qode-nodejs/qode-v1.0.2.zip'
Now downloading a fresh copy of qode-v1.0.2 from Github...
Downloading from:  https://github.com/nodegui/qode/releases/download/v1.0.2/linux-x64.zip
downloading [====================================================================================================] 100% of 39.4 Mb 0.0s
Local Qode 1.0.2 archive doesnt exists... Copying Qode from cache...
Extracting binaries...

> @nodegui/[email protected] postinstall /home/vince/test/nodegui/node_modules/@nodegui/nodegui
> npm run build:addon


> @nodegui/[email protected] build:addon /home/vince/test/nodegui/node_modules/@nodegui/nodegui
> node-gyp -j 8 configure build

make: Entering directory '/home/vince/test/nodegui/node_modules/@nodegui/nodegui/build'
  CC(target) Release/obj.target/nothing/../../node-addon-api/src/nothing.o
  AR(target) Release/obj.target/../../node-addon-api/src/nothing.a
  COPY Release/nothing.a
  CXX(target) Release/obj.target/qtnode/src/cpp/main.o
  CXX(target) Release/obj.target/qtnode/src/cpp/Extras/Utils/nutils.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexlayout.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexitem.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/YogaWidget/nodestyle.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/Events/eventsmap.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/Events/eventwidget.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/YogaWidget/yogawidget.o
  CXX(target) Release/obj.target/qtnode/src/cpp/QtGui/QApplication/qapplication_wrap.o
In file included from /usr/include/c++/5/bits/hashtable.h:35:0,
                 from /usr/include/c++/5/unordered_map:47,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from ../src/cpp/core/Events/eventwidget.h:4,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/bits/hashtable_policy.h: In instantiation of β€˜struct std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> >’:
/usr/include/c++/5/type_traits:137:12:   required from β€˜struct std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
/usr/include/c++/5/type_traits:148:38:   required from β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
../src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/hashtable_policy.h:85:34: error: no match for call to β€˜(const std::hash<QEvent::Type>) (const QEvent::Type&)’
  noexcept(declval<const _Hash&>()(declval<const _Key&>()))>
                                  ^
In file included from /home/vince/test/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/qglobal.h:45:0,
                 from /home/vince/test/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/qnamespace.h:43,
                 from /home/vince/test/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/qcoreevent.h:43,
                 from /home/vince/test/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/QEvent:1,
                 from ../src/cpp/core/Events/eventwidget.h:3,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/type_traits: In instantiation of β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’:
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
../src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/type_traits:148:38: error: β€˜value’ is not a member of β€˜std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
     : public integral_constant<bool, !_Pp::value>
                                      ^
In file included from /usr/include/c++/5/unordered_map:48:0,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from ../src/cpp/core/Events/eventwidget.h:4,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/bits/unordered_map.h: In instantiation of β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’:
../src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/unordered_map.h:100:66: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef __umap_hashtable<_Key, _Tp, _Hash, _Pred, _Alloc>  _Hashtable;
                                                                  ^
/usr/include/c++/5/bits/unordered_map.h:107:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_type key_type;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:108:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::value_type value_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:109:48: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::mapped_type mapped_type;
                                                ^
/usr/include/c++/5/bits/unordered_map.h:110:43: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::hasher hasher;
                                           ^
/usr/include/c++/5/bits/unordered_map.h:111:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_equal key_equal;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:112:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::allocator_type allocator_type;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:117:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::pointer  pointer;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:118:50: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_pointer const_pointer;
                                                  ^
/usr/include/c++/5/bits/unordered_map.h:119:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::reference  reference;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:120:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_reference const_reference;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:121:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::iterator  iterator;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:122:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_iterator const_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:123:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::local_iterator local_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:124:57: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_local_iterator const_local_iterator;
                                                         ^
/usr/include/c++/5/bits/unordered_map.h:125:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::size_type  size_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:126:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::difference_type difference_type;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:280:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       operator=(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:379:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  emplace(_Args&&... __args)
  ^
/usr/include/c++/5/bits/unordered_map.h:432:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(const value_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:439:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  insert(_Pair&& __x)
  ^
/usr/include/c++/5/bits/unordered_map.h:499:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:645:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:649:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x) const
       ^
  CXX(target) Release/obj.target/qtnode/src/cpp/QtGui/QEvent/QKeyEvent/qkeyevent_wrap.o
  CXX(target) Release/obj.target/qtnode/src/cpp/QtGui/QPixmap/qpixmap_wrap.o
In file included from /usr/include/c++/5/bits/hashtable.h:35:0,
                 from /usr/include/c++/5/unordered_map:47,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from .././src/cpp/core/Events/eventwidget.h:4,
                 from .././src/cpp/core/Events/eventwidget_macro.h:3,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_macro.h:5,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_wrap.h:3,
                 from ../src/cpp/main.cpp:2:
/usr/include/c++/5/bits/hashtable_policy.h: In instantiation of β€˜struct std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> >’:
/usr/include/c++/5/type_traits:137:12:   required from β€˜struct std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
/usr/include/c++/5/type_traits:148:38:   required from β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
.././src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/hashtable_policy.h:85:34: error: no match for call to β€˜(const std::hash<QEvent::Type>) (const QEvent::Type&)’
  noexcept(declval<const _Hash&>()(declval<const _Key&>()))>
                                  ^
In file included from /usr/include/c++/5/bits/move.h:57:0,
                 from /usr/include/c++/5/bits/stl_function.h:60,
                 from /usr/include/c++/5/functional:49,
                 from /home/vince/test/nodegui/node_modules/node-addon-api/napi.h:5,
                 from .././src/cpp/QtGui/QApplication/qapplication_wrap.h:3,
                 from ../src/cpp/main.cpp:1:
/usr/include/c++/5/type_traits: In instantiation of β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’:
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
.././src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/type_traits:148:38: error: β€˜value’ is not a member of β€˜std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
     : public integral_constant<bool, !_Pp::value>
                                      ^
In file included from /usr/include/c++/5/unordered_map:48:0,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from .././src/cpp/core/Events/eventwidget.h:4,
                 from .././src/cpp/core/Events/eventwidget_macro.h:3,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_macro.h:5,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_wrap.h:3,
                 from ../src/cpp/main.cpp:2:
/usr/include/c++/5/bits/unordered_map.h: In instantiation of β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’:
.././src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/unordered_map.h:100:66: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef __umap_hashtable<_Key, _Tp, _Hash, _Pred, _Alloc>  _Hashtable;
                                                                  ^
/usr/include/c++/5/bits/unordered_map.h:107:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_type key_type;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:108:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::value_type value_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:109:48: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::mapped_type mapped_type;
                                                ^
/usr/include/c++/5/bits/unordered_map.h:110:43: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::hasher hasher;
                                           ^
/usr/include/c++/5/bits/unordered_map.h:111:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_equal key_equal;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:112:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::allocator_type allocator_type;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:117:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::pointer  pointer;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:118:50: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_pointer const_pointer;
                                                  ^
/usr/include/c++/5/bits/unordered_map.h:119:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::reference  reference;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:120:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_reference const_reference;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:121:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::iterator  iterator;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:122:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_iterator const_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:123:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::local_iterator local_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:124:57: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_local_iterator const_local_iterator;
                                                         ^
/usr/include/c++/5/bits/unordered_map.h:125:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::size_type  size_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:126:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::difference_type difference_type;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:280:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       operator=(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:379:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  emplace(_Args&&... __args)
  ^
/usr/include/c++/5/bits/unordered_map.h:432:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(const value_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:439:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  insert(_Pair&& __x)
  ^
/usr/include/c++/5/bits/unordered_map.h:499:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:645:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:649:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x) const
       ^
../src/cpp/core/Events/eventwidget.cpp: In member function β€˜void EventWidget::subscribeToQtEvent(std::__cxx11::string)’:
../src/cpp/core/Events/eventwidget.cpp:8:86: error: no matching function for call to β€˜std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >::insert(<brace-enclosed initializer list>)’
         this->subscribedEvents.insert({static_cast<QEvent::Type>(evtType), evtString});
                                                                                      ^
In file included from /usr/include/c++/5/unordered_map:48:0,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from ../src/cpp/core/Events/eventwidget.h:4,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/bits/unordered_map.h:488:2: note: candidate: template<class _InputIterator> void std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(_InputIterator, _InputIterator) [with _InputIterator = _InputIterator; _Key = QEvent::Type; _Tp = std::__cxx11::basic_string<char>; _Hash = std::hash<QEvent::Type>; _Pred = std::equal_to<QEvent::Type>; _Alloc = std::allocator<std::pair<const QEvent::Type, std::__cxx11::basic_string<char> > >]
  insert(_InputIterator __first, _InputIterator __last)
  ^
/usr/include/c++/5/bits/unordered_map.h:488:2: note:   template argument deduction/substitution failed:
../src/cpp/core/Events/eventwidget.cpp:8:86: note:   candidate expects 2 arguments, 1 provided
         this->subscribedEvents.insert({static_cast<QEvent::Type>(evtType), evtString});
                                                                                      ^
../src/cpp/core/Events/eventwidget.cpp:9:115: error: β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’ has no member named β€˜size’
         spdlog::info("EventWidget: subscribed to {} : {}, size: {}", evtString.c_str(), evtType, subscribedEvents.size());
                                                                                                                   ^
../src/cpp/core/Events/eventwidget.cpp: In member function β€˜void EventWidget::unSubscribeToQtEvent(std::__cxx11::string)’:
../src/cpp/core/Events/eventwidget.cpp:18:32: error: β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’ has no member named β€˜erase’
         this->subscribedEvents.erase(static_cast<QEvent::Type>(evtType));             // erasing by key
                                ^
../src/cpp/core/Events/eventwidget.cpp: In member function β€˜void EventWidget::event(QEvent*)’:
../src/cpp/core/Events/eventwidget.cpp:29:60: error: β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’ has no member named β€˜at’
             std::string eventTypeString = subscribedEvents.at(evtType);
                                                            ^
qtnode.target.mk:171: recipe for target 'Release/obj.target/qtnode/src/cpp/main.o' failed
make: *** [Release/obj.target/qtnode/src/cpp/main.o] Error 1
make: *** Waiting for unfinished jobs....
qtnode.target.mk:171: recipe for target 'Release/obj.target/qtnode/src/cpp/core/Events/eventwidget.o' failed
make: *** [Release/obj.target/qtnode/src/cpp/core/Events/eventwidget.o] Error 1
make: Leaving directory '/home/vince/test/nodegui/node_modules/@nodegui/nodegui/build'
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/home/vince/.nvm/versions/node/v12.8.1/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:196:23)
gyp ERR! stack     at ChildProcess.emit (events.js:203:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 4.15.0-58-generic
gyp ERR! command "/home/vince/.nvm/versions/node/v12.8.1/bin/node" "/home/vince/.nvm/versions/node/v12.8.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "-j" "8" "configure" "build"
gyp ERR! cwd /home/vince/test/nodegui/node_modules/@nodegui/nodegui
gyp ERR! node -v v12.8.1
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @nodegui/[email protected] build:addon: `node-gyp -j 8 configure build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the @nodegui/[email protected] build:addon script.

QPixmap doesn't work in Linux

I started using the react-nodegui-starter project and it starts with a black background:

error

I thought this was just a demo but looking at the code there's supposed to be an image there.

I started looking at the source of the <Image /> component and went all the way up to QPixmap, which is why I'm creating the issue here.

The terminal shows this when I run the project:

QPixmap::scaled: Pixmap is a null pixmap

Steps to reproduce:

  1. Clone react-nodegui-starter
  2. Run npm install
  3. Run npm start

The window should open with a black background and no image.

System

  • OS: Pop!_OS 19.04 x86_64
  • node v12.8.1 (npm v6.10.3)
  • gcc version 8.3.0 (Ubuntu 8.3.0-6ubuntu1)

How to make contributions (adding features, methods etc)?

Hi,
I'm exploring this project right now and I have to say its pretty frickin awesome πŸ‘

I would like to evaluate it as a platform for my next project and was wondering how could I tacke moving with mouse/changing position of a window with WindowType.FramelessWindowHint flag (as used in weather widget example)?

The setGeometry/move seems to be lacking implementation? Or I'm just simply missing something?

Ohhh! And sorry for using issue tracker as a community board but I did not see any other communication channel available.

Deploying with 'pkg'?

I have read that there is on-going development for deploying and cross-compiling apps. I haven't tested yet, but maybe nodegui can work with 'pkg' by Zeit.

The theoretical problem I'm assuming that can occur is because 'pkg' actually binds a patched node into the final executable, causing problems with 'qode' (and also increase the executable size). Otherwise we could just implement pkg to bundle the final executable.

Native notifications

hi
with the electron, since it is based on electron you can use Notification class, in nodegui how we can use os native notification system?

[Discussion] Test runner

We need to implement a E2E/Unit test runner much like how JSDOM and Jest is implemented.

I don't have much Qt5 knowledge, but I know that you can switch out the workers in e.g Jest and run the specific tests with Qode as the executor instead of Node.
But is there some way to mock the implementation and disable the GUI so that users can assert against the state of e.g widgets?

TabWidget doesnt work well with FlexLayout

Describe the bug

const tabs = new QTabWidget();
tabs.setTabsClosable(true);
const tab1 = new QWidget();
const tab2 = new QWidget();
tab1.setLayout(new QGridLayout()); //Chaning this to FlexLayout doesnt work
tab2.setLayout(new QGridLayout());

if (tab1.layout && tab2.layout) {
  tab1.layout.addWidget(label1);
  tab2.layout.addWidget(label2);
}

tabs.addTab(tab1, icon, "Tab 1");
tabs.addTab(tab2, icon, "Tab 2");

To Reproduce
As above

Expected behavior
FlexLayout should work with tab widget

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. Mac, Linux, Win]
  • NodeGUI version
  • OS Version

Additional context
Add any other context about the problem here.

Fix inheritance of qt stylesheet flex props

Currently, when we set flex properties in QT
It gets propagated to all its child widgets. This shouldnt happen. As flex properties do not cascade in web world.

This happens because qt just cascades all the stylesheet props except color and font styles by default.

For time being we can overcome this by implementing stylesheet overrides in child widgets whenever we instantiate a child.

Non child orphan widgets get garbage collected and break entire app

If there is are widgets/layouts and they are not a child of any other widget. They get garbage collected (as they should) but this causes the program to break since after they get garbage collected they throw

qode(51971,0x1072665c0) malloc: *** error for object 0x102d51380: pointer being freed was not allocated
qode(51971,0x1072665c0) malloc: *** set a breakpoint in malloc_error_break to debug
/bin/sh: line 1: 51971 Abort trap: 6           qode dist/examples/calculator/index.js

This is because the js object got freed and along with that the memory for it. so when it tries to clear it again this causes seg fault!

How to prevent text wrapping in QPlainTextEdit?

I have a QPlainTextEdit on which I wish to display a random combination of letters, numbers and special characters (a password, basically).

When the text is only letters and numbers, the output runs from left to right with no breaks (as one would expect). It only wraps when it hits the edge of the QPlainTextEdit.

passOutput.setPlainText(
  'AS0dlkqVDmC5L8mKhNAmVU7Ww2j9LiCFo6k43uR6lngZ0Prr2I1xRF7Y64PF92j87V'
);

qode_001

However, if the text contains certain special characters an undesired line break is inserted. E.g.:

passOutput.setPlainText(
  '2VB#t>ZQyS.*|t`=t=AdB=s9gyNKt%Up9q:fKpL]DKB-5:g),cneAg4(bH:A9hF/cH'
);

qode_002

Notice the line break after the | character.

My question: is there any way to prevent this?

I would like the text containing the special characters to run from left to right and only wrap when the edge of the QPlainTextEdit is reached (like the example containing just letters and numbers).

I tried styling the QPlainTextEdit using word-break: break-all, but it didn't make a difference.

Looking through the QT docs, I did find this: https://doc.qt.io/qt-5/qtextoption.html#WrapMode-enum

Is something like wrap mode available in NodeGUI?

error C2039 'init': is not a member of 'QTabWidget'

Hi,
I was trying to implement QTabWidget into nodegui but I have hit major issue where my npm run build:addon ends with such an error log:

error C2039 'init': is not a member of 'QTabWidget'
error C3861: 'init': identifier not found

while as far as I can tell the declaration is identical as in let's say QProgressBar.

You can see all the changed code under: Uriziel01@7e9baa2

Any suggestions/hints for a guy that haven't written Cpp in years?

Fails to install dependencies with gcc 5 on linux

Hello! When I saw this project I got super excited because it looks awesome. I wanted to start right away.

The documentation claims that all I need is node + npm. I saw (in very small print :P) that it only works with node 12 and up..

My system is:

Ubuntu 16.04 64 bits
Node 12.8.1
npm 6.10.1

In this project and also in react-nodegui-starter and nodegui-starter I always get the same error. It fails to build either nodegui or qode with what seems to be a similar error.

I'm clearly missing something and I swear I went through the docs. They say I can just clone the repo, npm install and I should be good to go but that doesn't seem to be the case.

I also tried to install qode directly following the README there. I installed Qt5 following the instructions there, then running this:

QT_INSTALL_DIR=/home/nahuel.jose/Qt5.13.0/5.13.0/gcc_64 node build.js

says:

python: can't open file 'configure': [Errno 2] No such file or directory

Here's the full log from npm install on this project. Thanks!


> @nodegui/[email protected] postinstall /home/nahuel.jose/Proyectos/Personal/nodegui/node_modules/@nodegui/qode
> node install.js

Local Qode 1.0.2 archive doesnt exists... Copying Qode from cache...
Extracting binaries...

> @nodegui/[email protected] install /home/nahuel.jose/Proyectos/Personal/nodegui
> npm -v

6.10.2

> @nodegui/[email protected] postinstall /home/nahuel.jose/Proyectos/Personal/nodegui
> npm run build:addon


> @nodegui/[email protected] build:addon /home/nahuel.jose/Proyectos/Personal/nodegui
> node-gyp -j 8 configure build

make: Entering directory '/home/nahuel.jose/Proyectos/Personal/nodegui/build'
  CC(target) Release/obj.target/nothing/node_modules/node-addon-api/src/nothing.o
  AR(target) Release/obj.target/node_modules/node-addon-api/src/nothing.a
  COPY Release/nothing.a
  CXX(target) Release/obj.target/qtnode/src/cpp/main.o
  CXX(target) Release/obj.target/qtnode/src/cpp/Extras/Utils/nutils.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexlayout.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexitem.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/YogaWidget/nodestyle.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/Events/eventsmap.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/Events/eventwidget.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/YogaWidget/yogawidget.o
  CXX(target) Release/obj.target/qtnode/src/cpp/QtGui/QApplication/qapplication_wrap.o
In file included from /usr/include/c++/5/bits/hashtable.h:35:0,
                 from /usr/include/c++/5/unordered_map:47,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from ../src/cpp/core/Events/eventwidget.h:4,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/bits/hashtable_policy.h: In instantiation of β€˜struct std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> >’:
/usr/include/c++/5/type_traits:137:12:   required from β€˜struct std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
/usr/include/c++/5/type_traits:148:38:   required from β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
../src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/hashtable_policy.h:85:34: error: no match for call to β€˜(const std::hash<QEvent::Type>) (const QEvent::Type&)’
  noexcept(declval<const _Hash&>()(declval<const _Key&>()))>
                                  ^
In file included from /home/nahuel.jose/Proyectos/Personal/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/qglobal.h:45:0,
                 from /home/nahuel.jose/Proyectos/Personal/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/qnamespace.h:43,
                 from /home/nahuel.jose/Proyectos/Personal/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/qcoreevent.h:43,
                 from /home/nahuel.jose/Proyectos/Personal/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore/QEvent:1,
                 from ../src/cpp/core/Events/eventwidget.h:3,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/type_traits: In instantiation of β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’:
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
../src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/type_traits:148:38: error: β€˜value’ is not a member of β€˜std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
     : public integral_constant<bool, !_Pp::value>
                                      ^
In file included from /usr/include/c++/5/unordered_map:48:0,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from ../src/cpp/core/Events/eventwidget.h:4,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/bits/unordered_map.h: In instantiation of β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’:
../src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/unordered_map.h:100:66: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef __umap_hashtable<_Key, _Tp, _Hash, _Pred, _Alloc>  _Hashtable;
                                                                  ^
/usr/include/c++/5/bits/unordered_map.h:107:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_type key_type;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:108:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::value_type value_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:109:48: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::mapped_type mapped_type;
                                                ^
/usr/include/c++/5/bits/unordered_map.h:110:43: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::hasher hasher;
                                           ^
/usr/include/c++/5/bits/unordered_map.h:111:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_equal key_equal;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:112:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::allocator_type allocator_type;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:117:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::pointer  pointer;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:118:50: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_pointer const_pointer;
                                                  ^
/usr/include/c++/5/bits/unordered_map.h:119:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::reference  reference;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:120:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_reference const_reference;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:121:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::iterator  iterator;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:122:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_iterator const_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:123:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::local_iterator local_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:124:57: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_local_iterator const_local_iterator;
                                                         ^
/usr/include/c++/5/bits/unordered_map.h:125:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::size_type  size_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:126:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::difference_type difference_type;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:280:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       operator=(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:379:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  emplace(_Args&&... __args)
  ^
/usr/include/c++/5/bits/unordered_map.h:432:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(const value_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:439:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  insert(_Pair&& __x)
  ^
/usr/include/c++/5/bits/unordered_map.h:499:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:645:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:649:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x) const
       ^
  CXX(target) Release/obj.target/qtnode/src/cpp/QtGui/QEvent/QKeyEvent/qkeyevent_wrap.o
  CXX(target) Release/obj.target/qtnode/src/cpp/QtGui/QPixmap/qpixmap_wrap.o
In file included from /usr/include/c++/5/bits/hashtable.h:35:0,
                 from /usr/include/c++/5/unordered_map:47,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from .././src/cpp/core/Events/eventwidget.h:4,
                 from .././src/cpp/core/Events/eventwidget_macro.h:3,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_macro.h:5,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_wrap.h:3,
                 from ../src/cpp/main.cpp:2:
/usr/include/c++/5/bits/hashtable_policy.h: In instantiation of β€˜struct std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> >’:
/usr/include/c++/5/type_traits:137:12:   required from β€˜struct std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
/usr/include/c++/5/type_traits:148:38:   required from β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
.././src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/hashtable_policy.h:85:34: error: no match for call to β€˜(const std::hash<QEvent::Type>) (const QEvent::Type&)’
  noexcept(declval<const _Hash&>()(declval<const _Key&>()))>
                                  ^
In file included from /usr/include/c++/5/bits/move.h:57:0,
                 from /usr/include/c++/5/bits/stl_function.h:60,
                 from /usr/include/c++/5/functional:49,
                 from /home/nahuel.jose/Proyectos/Personal/nodegui/node_modules/node-addon-api/napi.h:5,
                 from .././src/cpp/QtGui/QApplication/qapplication_wrap.h:3,
                 from ../src/cpp/main.cpp:1:
/usr/include/c++/5/type_traits: In instantiation of β€˜struct std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’:
/usr/include/c++/5/bits/unordered_map.h:100:66:   required from β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’
.././src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/type_traits:148:38: error: β€˜value’ is not a member of β€˜std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > >’
     : public integral_constant<bool, !_Pp::value>
                                      ^
In file included from /usr/include/c++/5/unordered_map:48:0,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from .././src/cpp/core/Events/eventwidget.h:4,
                 from .././src/cpp/core/Events/eventwidget_macro.h:3,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_macro.h:5,
                 from .././src/cpp/QtWidgets/QWidget/qwidget_wrap.h:3,
                 from ../src/cpp/main.cpp:2:
/usr/include/c++/5/bits/unordered_map.h: In instantiation of β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’:
.././src/cpp/core/Events/eventwidget.h:10:51:   required from here
/usr/include/c++/5/bits/unordered_map.h:100:66: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef __umap_hashtable<_Key, _Tp, _Hash, _Pred, _Alloc>  _Hashtable;
                                                                  ^
/usr/include/c++/5/bits/unordered_map.h:107:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_type key_type;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:108:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::value_type value_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:109:48: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::mapped_type mapped_type;
                                                ^
/usr/include/c++/5/bits/unordered_map.h:110:43: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::hasher hasher;
                                           ^
/usr/include/c++/5/bits/unordered_map.h:111:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::key_equal key_equal;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:112:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::allocator_type allocator_type;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:117:45: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::pointer  pointer;
                                             ^
/usr/include/c++/5/bits/unordered_map.h:118:50: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_pointer const_pointer;
                                                  ^
/usr/include/c++/5/bits/unordered_map.h:119:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::reference  reference;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:120:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_reference const_reference;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:121:46: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::iterator  iterator;
                                              ^
/usr/include/c++/5/bits/unordered_map.h:122:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_iterator const_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:123:51: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::local_iterator local_iterator;
                                                   ^
/usr/include/c++/5/bits/unordered_map.h:124:57: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::const_local_iterator const_local_iterator;
                                                         ^
/usr/include/c++/5/bits/unordered_map.h:125:47: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::size_type  size_type;
                                               ^
/usr/include/c++/5/bits/unordered_map.h:126:52: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       typedef typename _Hashtable::difference_type difference_type;
                                                    ^
/usr/include/c++/5/bits/unordered_map.h:280:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       operator=(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:379:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  emplace(_Args&&... __args)
  ^
/usr/include/c++/5/bits/unordered_map.h:432:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(const value_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:439:2: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
  insert(_Pair&& __x)
  ^
/usr/include/c++/5/bits/unordered_map.h:499:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       insert(initializer_list<value_type> __l)
       ^
/usr/include/c++/5/bits/unordered_map.h:645:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x)
       ^
/usr/include/c++/5/bits/unordered_map.h:649:7: error: β€˜value’ is not a member of β€˜std::__not_<std::__and_<std::__is_fast_hash<std::hash<QEvent::Type> >, std::__detail::__is_noexcept_hash<QEvent::Type, std::hash<QEvent::Type> > > >’
       equal_range(const key_type& __x) const
       ^
../src/cpp/core/Events/eventwidget.cpp: In member function β€˜void EventWidget::subscribeToQtEvent(std::__cxx11::string)’:
../src/cpp/core/Events/eventwidget.cpp:8:86: error: no matching function for call to β€˜std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >::insert(<brace-enclosed initializer list>)’
         this->subscribedEvents.insert({static_cast<QEvent::Type>(evtType), evtString});
                                                                                      ^
In file included from /usr/include/c++/5/unordered_map:48:0,
                 from .././src/cpp/core/Events/eventsmap.h:2,
                 from ../src/cpp/core/Events/eventwidget.h:4,
                 from ../src/cpp/core/Events/eventwidget.cpp:1:
/usr/include/c++/5/bits/unordered_map.h:488:2: note: candidate: template<class _InputIterator> void std::unordered_map<_Key, _Tp, _Hash, _Pred, _Alloc>::insert(_InputIterator, _InputIterator) [with _InputIterator = _InputIterator; _Key = QEvent::Type; _Tp = std::__cxx11::basic_string<char>; _Hash = std::hash<QEvent::Type>; _Pred = std::equal_to<QEvent::Type>; _Alloc = std::allocator<std::pair<const QEvent::Type, std::__cxx11::basic_string<char> > >]
  insert(_InputIterator __first, _InputIterator __last)
  ^
/usr/include/c++/5/bits/unordered_map.h:488:2: note:   template argument deduction/substitution failed:
../src/cpp/core/Events/eventwidget.cpp:8:86: note:   candidate expects 2 arguments, 1 provided
         this->subscribedEvents.insert({static_cast<QEvent::Type>(evtType), evtString});
                                                                                      ^
../src/cpp/core/Events/eventwidget.cpp:9:115: error: β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’ has no member named β€˜size’
         spdlog::info("EventWidget: subscribed to {} : {}, size: {}", evtString.c_str(), evtType, subscribedEvents.size());
                                                                                                                   ^
../src/cpp/core/Events/eventwidget.cpp: In member function β€˜void EventWidget::unSubscribeToQtEvent(std::__cxx11::string)’:
../src/cpp/core/Events/eventwidget.cpp:18:32: error: β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’ has no member named β€˜erase’
         this->subscribedEvents.erase(static_cast<QEvent::Type>(evtType));             // erasing by key
                                ^
../src/cpp/core/Events/eventwidget.cpp: In member function β€˜void EventWidget::event(QEvent*)’:
../src/cpp/core/Events/eventwidget.cpp:29:60: error: β€˜class std::unordered_map<QEvent::Type, std::__cxx11::basic_string<char> >’ has no member named β€˜at’
             std::string eventTypeString = subscribedEvents.at(evtType);
                                                            ^
qtnode.target.mk:171: recipe for target 'Release/obj.target/qtnode/src/cpp/main.o' failed
make: *** [Release/obj.target/qtnode/src/cpp/main.o] Error 1
make: *** Waiting for unfinished jobs....
qtnode.target.mk:171: recipe for target 'Release/obj.target/qtnode/src/cpp/core/Events/eventwidget.o' failed
make: *** [Release/obj.target/qtnode/src/cpp/core/Events/eventwidget.o] Error 1
make: Leaving directory '/home/nahuel.jose/Proyectos/Personal/nodegui/build'
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/home/nahuel.jose/.nvm/versions/node/v12.8.1/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:196:23)
gyp ERR! stack     at ChildProcess.emit (events.js:203:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 4.4.0-72-generic
gyp ERR! command "/home/nahuel.jose/.nvm/versions/node/v12.8.1/bin/node" "/home/nahuel.jose/.nvm/versions/node/v12.8.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "-j" "8" "configure" "build"
gyp ERR! cwd /home/nahuel.jose/Proyectos/Personal/nodegui
gyp ERR! node -v v12.8.1
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @nodegui/[email protected] build:addon: `node-gyp -j 8 configure build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the @nodegui/[email protected] build:addon script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/nahuel.jose/.npm/_logs/2019-08-16T19_08_32_392Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @nodegui/[email protected] postinstall: `npm run build:addon`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the @nodegui/[email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/nahuel.jose/.npm/_logs/2019-08-16T19_08_32_535Z-debug.log

App crash via qode (v1.0.2, v1.0.3 and v1.0.4) on Mac Mojave v10.14.6

Hello, using qode v1.0.2, v1.0.3 and v1.0.4, a running app will crash after running for ~7s (via npm start).

Here's my error report:

Process:               qode [24607]
Path:                  /Users/USER/*/qode
Identifier:            qode
Version:               0
Code Type:             X86-64 (Native)
Parent Process:        ??? [24606]
Responsible:           qode [24607]

Crashed Thread:        0  Dispatch queue: com.apple.main-thread

Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       EXC_I386_GPFLT
Exception Note:        EXC_CORPSE_NOTIFY

Termination Signal:    Segmentation fault: 11
Termination Reason:    Namespace SIGNAL, Code 0xb
Terminating Process:   exc handler [24607]

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   qtnode.node                     0x00000001085b3e4d FlexLayoutWrap::~FlexLayoutWrap() + 21 (flexlayout_wrap.cpp:42)
1   qtnode.node                     0x00000001085b539a Napi::ObjectWrap<FlexLayoutWrap>::FinalizeCallback(napi_env__*, void*, void*) + 22 (napi-inl.h:3407)
2   qode                            0x000000010005ce8c 0x100000000 + 380556
3   qode                            0x00000001005e5e53 v8::internal::GlobalHandles::InvokeSecondPassPhantomCallbacksFromTask() + 339
4   qode                            0x00000001000dec91 node::PerIsolatePlatformData::RunForegroundTask(std::__1::unique_ptr<v8::Task, std::__1::default_delete<v8::Task> >) + 171
5   qode                            0x00000001000ddfad node::PerIsolatePlatformData::FlushForegroundTasksInternal() + 513
6   qode                            0x0000000100d77d3b 0x100000000 + 14122299
7   qode                            0x0000000100d87bf7 0x100000000 + 14187511
8   qode                            0x0000000100d781cf uv_run + 320
9   qode                            0x00000001001624ad qode::NodeIntegration::UvRunOnce() + 193
10  libdispatch.dylib               0x00007fff5aac45f8 _dispatch_call_block_and_release + 12
11  libdispatch.dylib               0x00007fff5aac563d _dispatch_client_callout + 8
12  libdispatch.dylib               0x00007fff5aad068d _dispatch_main_queue_callback_4CF + 1135
13  com.apple.CoreFoundation        0x00007fff2ebbd2d7 __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 9
14  com.apple.CoreFoundation        0x00007fff2ebbca01 __CFRunLoopRun + 2289
15  com.apple.CoreFoundation        0x00007fff2ebbbebe CFRunLoopRunSpecific + 455
16  com.apple.HIToolbox             0x00007fff2de1b1ab RunCurrentEventLoopInMode + 292
17  com.apple.HIToolbox             0x00007fff2de1aee5 ReceiveNextEventCommon + 603
18  com.apple.HIToolbox             0x00007fff2de1ac76 _BlockUntilNextEventMatchingListInModeWithFilter + 64
19  com.apple.AppKit                0x00007fff2c1b379d _DPSNextEvent + 1135
20  com.apple.AppKit                0x00007fff2c1b248b -[NSApplication(NSEvent) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 1361
21  com.apple.AppKit                0x00007fff2c1ac5a8 -[NSApplication run] + 699
22  libqcocoa.dylib                 0x00000001032b3e2b QCocoaEventDispatcher::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) + 2955
23  org.qt-project.QtCore           0x0000000101e0196f QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) + 431
24  org.qt-project.QtCore           0x0000000101e06a02 QCoreApplication::exec() + 130
25  qode                            0x0000000100161f99 qode::RunLoopWrapper(node::Environment*) + 39
26  qode                            0x00000001000c284f node::NodeMainInstance::Run() + 387
27  qode                            0x000000010006ce62 node::Start(int, char**) + 210
28  qode                            0x0000000100162098 qode::Start(int, char**) + 178
29  libdyld.dylib                   0x00007fff5ab123d5 start + 1

Let me know if there's anything else you need. Thanks!

Code style

I think this project needs to enforce a proper code style guide like https://github.com/airbnb/javascript (or use prettier/tslint) because it's hard trying to be a contributor when errors pop up because features haven't been implemented using best practices possible.

All "methods" of classes in this project are defined as arrow functions instead of actual methods.

Screenshot

I have to run `npm install` twice on MacOS 10.14.4

I have to run npm install twice on MacOS 10.14.4

DESCRIPTION:

In order to run the starter app or the calculator example (both for vanilla node-gui), I have to run npm install twice in order for it to owrk.

TO REPRODUCE

Unfortunately, I was using the instructions from your docs (https://nodegui.github.io/nodegui/#/tutorial/first-app?id=hello-world)

# Clone the repository
$ git clone https://github.com/nodegui/nodegui-starter
# Go into the repository
$ cd nodegui-starter
# Install dependencies
$ npm install

EXPECTED BEHAVIOR

I was hoping I would be able to run npm install once and be able to then start the project up.

SCREENSHOTS:

Local Qode 1.0.2 archive doesnt exists... Copying Qode from cache...
Copying Qode from cache failed...  Error: ENOENT: no such file or directory, stat '/Users/hquinn/Library/Caches/qode-nodejs/qode-v1.0.2.zip'
Now downloading a fresh copy of qode-v1.0.2 from Github...
Downloading from:  https://github.com/nodegui/qode/releases/download/v1.0.2/darwin-x64.zip
downloading [==========================] 100% of 50.3 Mb 0.0s
Local Qode 1.0.2 archive doesnt exists... Copying Qode from cache...
{ [Error: ENOENT: no such file or directory, stat '/Users/hquinn/Library/Caches/qode-nodejs/qode-v1.0.2.zip']
  errno: -2,
  code: 'ENOENT',
  syscall: 'stat',
  path: '/Users/hquinn/Library/Caches/qode-nodejs/qode-v1.0.2.zip' }
Failed to install qode-v1.0.2
npm WARN [email protected] No repository field.

npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @nodegui/[email protected] postinstall: `node install.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the @nodegui/[email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/hquinn/.npm/_logs/2019-09-07T14_28_25_121Z-debug.log

DESKTOP:

MacOS 10.14.4
Node v10.16.0
NPM 6.9.0
package.json:

{
  "name": "nodegui-starter",
  "version": "1.0.0",
  "main": "index.js",
  "author": "Atul R <[email protected]>",
  "license": "MIT",
  "private": true,
  "scripts": {
    "build": "webpack -p",
    "start": "webpack && qode ./dist/index.js",
    "debug": "webpack && qode --inspect ./dist/index.js"
  },
  "dependencies": {
    "@nodegui/nodegui": "^0.1.7"
  },
  "devDependencies": {
    "@types/node": "^12.6.8",
    "file-loader": "^4.2.0",
    "node-loader": "^0.6.0",
    "ts-loader": "^6.0.4",
    "typescript": "^3.5.3",
    "webpack": "^4.39.2",
    "webpack-cli": "^3.3.6"
  }
}

TODO: Qt MOC

Currently every time we make changes to a file that contains Q_OBJECT we need to run qt's moc. Need to automate it.

Auto run qt's moc on files having Q_OBJECT

Can't be built when using Yarn

It's impossible to build this library using yarn

Steps to reproduce

$ git clone https://github.com/nodegui/examples
$ cd examples/react-nodegui/weather-app-widget
$ yarn install

Errors that gets thrown:

yarn global v1.17.3
[1/4] Resolving packages...
β’€ [email protected](node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
(node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
(node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
(node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
(node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
⠐ ansi-regex@^3.0.0(node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
(node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
(node:28235) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[2/2] β „ @nodegui/nodegui
error /usr/local/share/.config/yarn/global/node_modules/@nodegui/nodegui: Command failed.
Exit code: 243
Command: npm run build:addon
Arguments: 
Directory: /usr/local/share/.config/yarn/global/node_modules/@nodegui/nodegui
Output:

Linux: Platform plugin could be initialized (F30)

Hey,
after installing example React app and all Qt packages, I got into a problem when qode is not able to resolve plugins.

$ tsc && qode ./dist/index.js
Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.
qt.qpa.plugin: Could not find the Qt platform plugin "xcb" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

After I followed the advice I got

$ QT_QPA_PLATFORM=wayland qode ./dist/index.js
Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.
qt.qpa.plugin: Could not find the Qt platform plugin "wayland" in ""
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

I also tried turning on debugging mode and pointing manually to a path for platform plugins.

$ QT_DEBUG_PLUGINS=1 QT_QPA_PLATFORM_PLUGIN_PATH=/usr/lib64/qt5/plugins/platforms QT_QPA_PLATFORM=wayland qode ./dist/index.js
QFactoryLoader::QFactoryLoader() checking directory path "/usr/lib64/qt5/plugins/platforms" ...
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqeglfs.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqeglfs.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "eglfs"
        ]
    },
    "archreq": 0,
    "className": "QEglFSIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("eglfs")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqlinuxfb.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqlinuxfb.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "linuxfb"
        ]
    },
    "archreq": 0,
    "className": "QLinuxFbIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("linuxfb")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqminimal.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqminimal.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "minimal"
        ]
    },
    "archreq": 0,
    "className": "QMinimalIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("minimal")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqminimalegl.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqminimalegl.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "minimalegl"
        ]
    },
    "archreq": 0,
    "className": "QMinimalEglIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("minimalegl")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqoffscreen.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqoffscreen.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "offscreen"
        ]
    },
    "archreq": 0,
    "className": "QOffscreenIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("offscreen")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqvnc.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqvnc.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "vnc"
        ]
    },
    "archreq": 0,
    "className": "QVncIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("vnc")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqwayland-egl.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqwayland-egl.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "wayland-egl"
        ]
    },
    "archreq": 0,
    "className": "QWaylandEglPlatformIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("wayland-egl")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqwayland-generic.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqwayland-generic.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "wayland"
        ]
    },
    "archreq": 0,
    "className": "QWaylandIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("wayland")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqwayland-xcomposite-egl.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqwayland-xcomposite-egl.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "wayland-xcomposite-egl"
        ]
    },
    "archreq": 0,
    "className": "QWaylandXCompositeEglPlatformIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("wayland-xcomposite-egl")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqwayland-xcomposite-glx.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqwayland-xcomposite-glx.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "wayland-xcomposite-glx"
        ]
    },
    "archreq": 0,
    "className": "QWaylandXCompositeGlxPlatformIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("wayland-xcomposite-glx")
QFactoryLoader::QFactoryLoader() looking at "/usr/lib64/qt5/plugins/platforms/libqxcb.so"
Found metadata in lib /usr/lib64/qt5/plugins/platforms/libqxcb.so, metadata=
{
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
        "Keys": [
            "xcb"
        ]
    },
    "archreq": 0,
    "className": "QXcbIntegrationPlugin",
    "debug": false,
    "version": 330752
}


Got keys from plugin meta data ("xcb")
QFactoryLoader::QFactoryLoader() checking directory path "/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1" ...
QFactoryLoader::QFactoryLoader() looking at "/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/qode"
"Failed to extract plugin meta data from '/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/qode'" 
         not a plugin
QFactoryLoader::QFactoryLoader() looking at "/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/qode-v1.0.1.zip"
QElfParser: '/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/qode-v1.0.1.zip' is not an ELF object
"'/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/qode-v1.0.1.zip' is not an ELF object" 
         not a plugin
QFactoryLoader::QFactoryLoader() checking directory path "/usr/lib64/qt5/plugins/platforms/platforms" ...
QFactoryLoader::QFactoryLoader() checking directory path "/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/platforms" ...
Cannot load library /usr/lib64/qt5/plugins/platforms/libqwayland-generic.so: (/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/lib/libQt5Gui.so.5: version `Qt_5.12.4_PRIVATE_API' not found (required by /usr/lib64/qt5/plugins/platforms/libqwayland-generic.so))
QLibraryPrivate::loadPlugin failed on "/usr/lib64/qt5/plugins/platforms/libqwayland-generic.so" : "Cannot load library /usr/lib64/qt5/plugins/platforms/libqwayland-generic.so: (/home/sladg/Documents/nodegui/react-nodegui-starter/node_modules/@nodegui/qode/dist/1.0.1/lib/libQt5Gui.so.5: version `Qt_5.12.4_PRIVATE_API' not found (required by /usr/lib64/qt5/plugins/platforms/libqwayland-generic.so))"
qt.qpa.plugin: Could not find the Qt platform plugin "wayland" in "/usr/lib64/qt5/plugins/platforms"
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: eglfs (from /usr/lib64/qt5/plugins/platforms), linuxfb (from /usr/lib64/qt5/plugins/platforms), minimal (from /usr/lib64/qt5/plugins/platforms), minimalegl (from /usr/lib64/qt5/plugins/platforms), offscreen (from /usr/lib64/qt5/plugins/platforms), vnc (from /usr/lib64/qt5/plugins/platforms), wayland-egl (from /usr/lib64/qt5/plugins/platforms), wayland (from /usr/lib64/qt5/plugins/platforms), wayland-xcomposite-egl (from /usr/lib64/qt5/plugins/platforms), wayland-xcomposite-glx (from /usr/lib64/qt5/plugins/platforms), xcb (from /usr/lib64/qt5/plugins/platforms).

Done in 0.45s.

Without a luck.

I'm running Fedora 30
Linux thinkaboutme 5.2.8-200.fc30.x86_64 #1 SMP Sat Aug 10 13:21:39 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

All qt packages installed

qt.x86_64                                         1:4.8.7-49.fc30                        @updates               
qt-common.noarch                                  1:4.8.7-49.fc30                        @updates               
qt-settings.noarch                                30.3-1.fc30                            @updates               
qt-x11.x86_64                                     1:4.8.7-49.fc30                        @updates               
qt5.noarch                                        5.12.4-1.fc30                          @updates               
qt5-designer.x86_64                               5.12.4-1.fc30                          @updates               
qt5-devel.noarch                                  5.12.4-1.fc30                          @updates               
qt5-doctools.x86_64                               5.12.4-1.fc30                          @updates               
qt5-linguist.x86_64                               5.12.4-1.fc30                          @updates               
qt5-qdbusviewer.x86_64                            5.12.4-1.fc30                          @updates               
qt5-qt3d.x86_64                                   5.12.4-1.fc30                          @updates               
qt5-qt3d-devel.x86_64                             5.12.4-1.fc30                          @updates               
qt5-qtbase.x86_64                                 5.12.4-4.fc30                          @updates               
qt5-qtbase-common.noarch                          5.12.4-4.fc30                          @updates               
qt5-qtbase-devel.x86_64                           5.12.4-4.fc30                          @updates               
qt5-qtbase-gui.x86_64                             5.12.4-4.fc30                          @updates               
qt5-qtbase-mysql.x86_64                           5.12.4-4.fc30                          @updates               
qt5-qtbase-postgresql.x86_64                      5.12.4-4.fc30                          @updates               
qt5-qtbase-static.x86_64                          5.12.4-4.fc30                          @updates               
qt5-qtconnectivity.x86_64                         5.12.4-1.fc30                          @updates               
qt5-qtconnectivity-devel.x86_64                   5.12.4-1.fc30                          @updates               
qt5-qtdeclarative.x86_64                          5.12.4-1.fc30                          @updates               
qt5-qtdeclarative-devel.x86_64                    5.12.4-1.fc30                          @updates               
qt5-qtdeclarative-static.x86_64                   5.12.4-1.fc30                          @updates               
qt5-qtdoc.noarch                                  5.12.4-1.fc30                          @updates               
qt5-qtenginio.x86_64                              1:1.6.2-24.fc30                        @updates               
qt5-qtenginio-devel.x86_64                        1:1.6.2-24.fc30                        @updates               
qt5-qtgraphicaleffects.x86_64                     5.12.4-1.fc30                          @updates               
qt5-qtimageformats.x86_64                         5.12.4-1.fc30                          @updates               
qt5-qtlocation.x86_64                             5.12.4-1.fc30                          @updates               
qt5-qtlocation-devel.x86_64                       5.12.4-1.fc30                          @updates               
qt5-qtmultimedia.x86_64                           5.12.4-1.fc30                          @updates               
qt5-qtmultimedia-devel.x86_64                     5.12.4-1.fc30                          @updates               
qt5-qtquickcontrols.x86_64                        5.12.4-1.fc30                          @updates               
qt5-qtquickcontrols2.x86_64                       5.12.4-1.fc30                          @updates               
qt5-qtscript.x86_64                               5.12.4-1.fc30                          @updates               
qt5-qtscript-devel.x86_64                         5.12.4-1.fc30                          @updates               
qt5-qtsensors.x86_64                              5.12.4-1.fc30                          @updates               
qt5-qtsensors-devel.x86_64                        5.12.4-1.fc30                          @updates               
qt5-qtserialport.x86_64                           5.12.4-1.fc30                          @updates               
qt5-qtserialport-devel.x86_64                     5.12.4-1.fc30                          @updates               
qt5-qtsvg.x86_64                                  5.12.4-1.fc30                          @updates               
qt5-qtsvg-devel.x86_64                            5.12.4-1.fc30                          @updates               
qt5-qttools.x86_64                                5.12.4-1.fc30                          @updates               
qt5-qttools-common.noarch                         5.12.4-1.fc30                          @updates               
qt5-qttools-devel.x86_64                          5.12.4-1.fc30                          @updates               
qt5-qttools-libs-designer.x86_64                  5.12.4-1.fc30                          @updates               
qt5-qttools-libs-designercomponents.x86_64        5.12.4-1.fc30                          @updates               
qt5-qttools-libs-help.x86_64                      5.12.4-1.fc30                          @updates               
qt5-qttools-static.x86_64                         5.12.4-1.fc30                          @updates               
qt5-qtwayland.x86_64                              5.12.4-7.fc30                          @updates               
qt5-qtwayland-devel.x86_64                        5.12.4-7.fc30                          @updates               
qt5-qtwebchannel.x86_64                           5.12.4-1.fc30                          @updates               
qt5-qtwebchannel-devel.x86_64                     5.12.4-1.fc30                          @updates               
qt5-qtwebkit.x86_64                               5.212.0-0.36.alpha2.fc30               @updates               
qt5-qtwebkit-devel.x86_64                         5.212.0-0.36.alpha2.fc30               @updates               
qt5-qtwebsockets.x86_64                           5.12.4-1.fc30                          @updates               
qt5-qtwebsockets-devel.x86_64                     5.12.4-1.fc30                          @updates               
qt5-qtx11extras.x86_64                            5.12.4-1.fc30                          @updates               
qt5-qtx11extras-devel.x86_64                      5.12.4-1.fc30                          @updates               
qt5-qtxmlpatterns.x86_64                          5.12.4-1.fc30                          @updates               
qt5-qtxmlpatterns-devel.x86_64                    5.12.4-1.fc30                          @updates               
qt5-rpm-macros.noarch                             5.12.4-1.fc30                          @updates               
qt5-srpm-macros.noarch                            5.12.4-1.fc30                          @updates  

I'm ultimately trying to get nodegui working with example app.

Fails to install on Linux when there is space in the path name - Pop!_OS 19.04 x86_64

I wanted to try this project out but am unable to install it on Linux. The install process errors out while running make.

My system specs

OS:
Neofetch

Node -> 12.8.1
npm -> 6.10.2
gcc -> (Ubuntu 8.3.0-6ubuntu1) 8.3.0
make -> 4.2.1

Steps to reproduce

  1. Download repo with SSH
  2. CD into directory
  3. run npm i

Terminal output

> @nodegui/[email protected] install /media/alejandro/ExtraDrive11/React Projects/nodegui
> npm -v

6.10.2

> @nodegui/[email protected] postinstall /media/alejandro/ExtraDrive11/React Projects/nodegui
> npm run build:addon


> @nodegui/[email protected] build:addon /media/alejandro/ExtraDrive11/React Projects/nodegui
> node-gyp -j 8 configure build

make: Entering directory '/media/alejandro/ExtraDrive11/React Projects/nodegui/build'
  CXX(target) Release/obj.target/qtnode/src/cpp/main.o
  CXX(target) Release/obj.target/qtnode/src/cpp/Extras/Utils/nutils.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexlayout.o
  CXX(target) Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexitem.o
g++: error: Projects/nodegui/node_modules/node-addon-api: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtGui: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtWidgets: No such file or directory
g++: error: Projects/nodegui/node_modules/node-addon-api: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtGui: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtWidgets: No such file or directory
make: *** [qtnode.target.mk:171: Release/obj.target/qtnode/src/cpp/main.o] Error 1
make: *** Waiting for unfinished jobs....
make: *** [qtnode.target.mk:171: Release/obj.target/qtnode/src/cpp/Extras/Utils/nutils.o] Error 1
  CXX(target) Release/obj.target/qtnode/src/cpp/core/YogaWidget/nodestyle.o
g++: error: Projects/nodegui/node_modules/node-addon-api: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtGui: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtWidgets: No such file or directory
make: *** [qtnode.target.mk:171: Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexlayout.o] Error 1
g++: error: Projects/nodegui/node_modules/node-addon-api: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtGui: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtWidgets: No such file or directory
g++: error: Projects/nodegui/node_modules/node-addon-api: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtCore: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtGui: No such file or directory
g++: error: Projects/nodegui/node_modules/@nodegui/qode/dist/1.0.2/include/QtWidgets: No such file or directory
make: *** [qtnode.target.mk:171: Release/obj.target/qtnode/src/cpp/core/FlexLayout/flexitem.o] Error 1
make: *** [qtnode.target.mk:171: Release/obj.target/qtnode/src/cpp/core/YogaWidget/nodestyle.o] Error 1
make: Leaving directory '/media/alejandro/ExtraDrive11/React Projects/nodegui/build'
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/home/alejandro/.nvm/versions/node/v12.8.1/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:196:23)
gyp ERR! stack     at ChildProcess.emit (events.js:203:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:272:12)
gyp ERR! System Linux 5.0.0-25-generic
gyp ERR! command "/home/alejandro/.nvm/versions/node/v12.8.1/bin/node" "/home/alejandro/.nvm/versions/node/v12.8.1/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "-j" "8" "configure" "build"
gyp ERR! cwd /media/alejandro/ExtraDrive11/React Projects/nodegui
gyp ERR! node -v v12.8.1
gyp ERR! node-gyp -v v5.0.3
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @nodegui/[email protected] build:addon: `node-gyp -j 8 configure build`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the @nodegui/[email protected] build:addon script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/alejandro/.npm/_logs/2019-08-17T11_46_26_966Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @nodegui/[email protected] postinstall: `npm run build:addon`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the @nodegui/[email protected] postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/alejandro/.npm/_logs/2019-08-17T11_46_26_983Z-debug.log

Things I've tried so far

I saw this issue - as well as the one opened by the same user for react-nodegui and tried the things that it suggested except for installing QT from their website.
#16

As you can see in the terminal output, it seems to be failing to copy files/folders. One thing to note (which I don't know if it's relevant or not) is that I don't have node-gyp installed globally, nor do I have the apt package installed.

This seems like a great project and I am excited about it, so any assistance would be greatly appreciated.

development on windows 10

I have visual studio 2015 installed and python 3.6, can I use nodegui ? or should i install vs 2017 and if yes what workloads should i install ?

Todo: Things to be done for Yoga/Flex

  • Need to implement YGMeasure for labels and text
  • Need to implement width and height via stylesheet
  • Need to implement custom autoprefixer
  • Bug: Initial rendering in case of nested layouts are not working properly. Current hack-fix is to resize on load.

What would one have to know in order to get Vue to work in NodeGUI?

I'm a much bigger fan of the the Vue ecosystem for apps with JavaScript. I haven't done that much engineering on a larger scale, but would be interested in the hopes of getting a Vue Native Desktop. Is there a resource you can point me to on how you did it with React?

Systray support?

Hi, this project looks pretty neat. I was wondering if nodegui has systray support to put an icon for the app in the system tray?

Cheers.

NodeGUI on JS Party?! πŸŽ‰

Cool project!! We'd love to have y'all come on the JS Party podcast and chat with us about it. Who would be the best person on your team to represent? πŸ€”

πŸ’šπŸ’šπŸ’š

Is it currently possible to get a QCheckBox's checked state?

In NodeGUI is it currently possible to get a QCheckBox's checked state?

In QT you can use isChecked() to query whether or not a checkbox is checked, but I could find no reference to this or anything similar in the NodeGUI docs or code base.

Also, is this a good place to ask questions? If not, could you please tell me where is.

I'm currently converting an small FXRuby app to use NodeGUI just to see how the two stack up against each other. I've run into one or two issues, but don't want to spam the repo.

Is the old nwidget_moc.cpp still necessary?

Inside of src/cpp/QtWidgets/Qwidget we are keeping file nwidget_moc.cpp with top comment clearly stating that it was build with old version of QT

Created by: The Qt Meta Object Compiler version 67 (Qt 5.12.1)

Can that file be safely removed? I've tries building project without it and everything seems to be working just fine.

Reusable components

We should have a dedicated repository for reusable components that the different renderers can depend on so we have less duplicate code.

For example I'm already reusing the ImageLabel from https://github.com/nodegui/react-nodegui/blob/master/src/components/Image/ImageLabel.ts as you can see here https://github.com/marcus-sa/ng-cute/blob/master/packages/common/src/image/image-label.ts

Or if we create the components using something else like Stencil, then we can reuse the exact same amongst all renderers where we only have to register them instead of replicating the same functionality.

So the idea is that you would normally register the components as custom schemas (web components) but then the custom renderers would of course identify these, since you can only use components which are provided NG (nodegui) and then use whatever logic that include, for React it's reconciler and for Angular just the Renderer2

Nodegui poc

This seems like a very promising project, something to keep following for sure! I share the frustration when it comes to developing apps with electron: including the full chromium runtime ftw?! While their api is unparalleled, I really think a simple app should't have to suffer from high cpu- and memory consumption.

That's why I'm always keen on looking for alternatives when it comes to developing lighter apps. To name just a few I have been reviewing previously: Electrino, Deskgap and Proton Native. While they all seem very promising, it also looks like they have been abandoned which I think is a real shame. The world needs a light Electron alternative people! So I'm glad to see this project is still alive!

Now, for a poc I'm doing I am evaluating nodegui as a potential option. Without going head-first and spend a lot of developer hours upfront, I would like to know whether nodegui is capable of the following:

  • Detect and process global keypresses (similar to Electron's globalShortcut)
  • Support exec method through node's child_process
  • Display animations. Simple like text hover but also more advanced like sliding a pane into view
  • Support power monitor api, like the one from Electron
  • Display a Systray (wip as per this issue?)

Thanks in advance!

Add funding links

Need to add funding links to funding.yml
This will help us focus more on this project and dedicate time.

TODO before launch

Required

Optional

  • Packaging / Deploying
  • More widgets, and methods to export.
  • Plugin/Native modules support - Like that of react native
  • Better devtools, livereload, hotreload and debugging integration.
  • Images support
  • canvas ?
  • Animation support?
  • Embedded webview ?
  • camera ?
  • CLI based app creation ?
  • Menu's toolbar on top ?

Example ideas:

  1. https://github.com/hokein/electron-sample-apps
  2. Floating clock
  3. https://github.com/sindresorhus/awesome-electron
  4. https://electronjs.org/blog/simple-samples

Tech debt:

  • Alternate backendfd polling:
get default uv loop in the addon
getBackendfd of nodejs main loop
attach a socketnotifier to backend fd
stop nodejs uvloop
onsocketnotifier // (this will send custom event to qt loop)
 do uv_loop_run no_wait on read.

[BUG] Layout calculation error after exiting fullscreen mode

The issue was reproduced on Windows 10

Steps to reproduce:
Build demo.ts from nodegui repository and double click window titlebar or click the fullscreen button. Repeat same action to leave fullscreen.

Expected result:
The window should be resized to its old size and all the widgets should be still visible

Actual result:
All the widgets disappear until user manually resizes the window once more.

EDIT:
It seems to be a layout calculation bug, elements are visible just centered against fullscreen window width instead of current width.

Remove postcss-nodegui-autoprefixer from runtime

I find it absurd that a transpiler plugin is being used at runtime, when in fact it belongs in a transpilation process, e.g when using Webpack (which the Angular wrapper has to).
The less overheat we can put on the GUI, the better performance it'll have, which is one of the key points of this project.

export class StyleSheet {
static create = async (cssString: string): Promise<string> => {
const { css } = await postcss([nodeguiAutoPrefixer()])
.process(cssString, { from: undefined })
.catch(err => {
console.warn(`Error autoprefixing`, err);
return { css: cssString };
});
return css;
};
}

nodegui-starter run `start` error

☁  nodegui-starter [master] cnpm start

> [email protected] start /Users/kozo4/cat/study/node/node-full/nodegui-starter
> tsc && qode ./dist/index.js

/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/bindings/bindings.js:135
  throw err;
  ^

Error: Could not locate the bindings file. Tried:
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/Debug/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/Release/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/out/Debug/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/Debug/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/out/Release/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/Release/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/default/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/compiled/12.6.1/darwin/x64/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/addon-build/release/install-root/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/addon-build/debug/install-root/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/addon-build/default/install-root/qtnode.node
 β†’ /Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/lib/binding/node-v72-darwin-x64/qtnode.node
    at Object.bindings [as default] (/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/bindings/bindings.js:126:9)
    at Object.<anonymous> (/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/dist/src/lib/core/addon.js:7:33)
    at Module._compile (internal/modules/cjs/loader.js:776:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:787:10)
    at Module.load (internal/modules/cjs/loader.js:643:32)
    at Function.Module._load (internal/modules/cjs/loader.js:556:12)
    at Module.require (internal/modules/cjs/loader.js:683:19)
    at require (internal/modules/cjs/helpers.js:16:16)
    at Object.<anonymous> (/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/dist/src/lib/QtGui/QApplication/index.js:6:33)
    at Module._compile (internal/modules/cjs/loader.js:776:30) {
  tries: [
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/Debug/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/Release/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/out/Debug/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/Debug/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/out/Release/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/Release/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/build/default/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/compiled/12.6.1/darwin/x64/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/addon-build/release/install-root/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/addon-build/debug/install-root/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/addon-build/default/install-root/qtnode.node',
    '/Users/kozo4/cat/study/node/node-full/nodegui-starter/node_modules/@nodegui/nodegui/lib/binding/node-v72-darwin-x64/qtnode.node'
  ]
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] start: `tsc && qode ./dist/index.js`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/kozo4/.npm/_logs/2019-08-19T01_25_07_026Z-debug.log

Define styles as javascript objects

Hi,
I was thinking about posting this into nodegui-react, but I think this is more of a general question. I'm currently using react-native for my app and through react-native-web I can use my react components within a nextjs app. This way I can share 100% of my components between native mobile and web.

It seems pretty easy to create an app with nodegui-react, but it might be hard to accomplish something like react-native-web, where through a simple webpack alias, all react-native imports are redirected to react-native-web, which shares the same API as react-native.

I guess this is not trivial to implement into nodegui, even though there already is View and Text components. Style definition for example works very different (react native: StyleSheet.create with a css defined as JS objects vs nodegui classic css strings).

Is there maybe some underlying API that would allow for css defined as JS? I'm trying to figure out how hard it'd be to create another layer on top of nodegui-react (something like react-native-nodegui) that'd allow the same, simple webpack aliasing as react-native-web.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.