Giter VIP home page Giter VIP logo

svelte-nodegui-starter'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!

svelte-nodegui-starter's People

Contributors

jonasgrunert avatar mlocik97 avatar shirakaba avatar

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

Watchers

 avatar  avatar  avatar  avatar

svelte-nodegui-starter's Issues

Trouble with Quickstart on Ubuntu 20.04

I found this project through a Hacker News post, as I suspect many did today! I followed the quickstart guide including these instructions, but am unable to install the dependencies:

$ npm install
npm ERR! code 1
npm ERR! path /home/benjamin/projects/svelte-nodegui-starter/node_modules/@nodegui/qode
npm ERR! command failed
npm ERR! command sh -c node install.js

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/benjamin/.npm/_logs/2021-03-06T05_32_53_936Z-debug.log

Snippet from the log file:

514 info run @nodegui/[email protected] postinstall node_modules/@nodegui/nodegui cross-env npm run setupqt && (node ./scripts/skip.js || npm run prebuild:install || npm run build:addon)
515 info run @nodegui/[email protected] postinstall node_modules/@nodegui/packer node ./scripts/setupBinaries.js
516 info run @nodegui/[email protected] postinstall node_modules/@nodegui/qode node install.js
517 info run [email protected] postinstall node_modules/svelte-preprocess echo "[svelte-preprocess] Don't forget to install the preprocessors packages that will be used: node-sass/sass, stylus, less, postcss & postcss-load-config, coffeescript, pug, etc..."
518 info run [email protected] postinstall { code: 0, signal: null }
519 timing build:run:postinstall:node_modules/svelte-preprocess Completed in 11ms
520 info run @nodegui/[email protected] postinstall { code: 1, signal: null }
521 timing reify:rollback:createSparse Completed in 249ms
522 timing reify:rollback:retireShallow Completed in 0ms
523 timing command:install Completed in 2056ms
524 verbose stack Error: command failed
524 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/@npmcli/promise-spawn/index.js:64:27)
524 verbose stack     at ChildProcess.emit (events.js:315:20)
524 verbose stack     at maybeClose (internal/child_process.js:1048:16)
524 verbose stack     at Socket.<anonymous> (internal/child_process.js:439:11)
524 verbose stack     at Socket.emit (events.js:315:20)
524 verbose stack     at Pipe.<anonymous> (net.js:673:12)
525 verbose pkgid @nodegui/[email protected]
526 verbose cwd /home/benjamin/projects/svelte-nodegui-starter
527 verbose Linux 5.8.0-44-generic
528 verbose argv "/snap/node/3790/bin/node" "/usr/local/bin/npm" "install"
529 verbose node v14.16.0
530 verbose npm  v7.6.0
531 error code 1
532 error path /home/benjamin/projects/svelte-nodegui-starter/node_modules/@nodegui/qode
533 error command failed
534 error command sh -c node install.js
535 verbose exit 1

It appears to be trouble with @nodegui/qode. Any ideas? Thanks for your help!

All npm scripts fail (`crypto/hash`, `RpcIpcMessage…` & `qode ENOENT`)

All the scripts just don’t work on a fresh clone with npm i. The first install warned me about an old lockfile, so apologies if I am necroposting. πŸ’€

EDIT: I guess NodeGUI project is dead rip. Looked interesting. πŸ˜•


For build and dev, two errors show up. The first one at node:internal/crypto/hash:69:

error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:69:19)

and the second a bit later in lib/rpc/rpc-ipc/RpcIpcMessagePort.js:47:47:

     triggerUncaughtException(err, true /* fromPromise */);
     ^

RpcIpcMessagePortClosedError: Cannot send the message - the message port has been closed for the process 31422.
    at …/svelte-nodegui-starter/node_modules/fork-ts-checker-webpack-plugin/lib/rpc/rpc-ipc/RpcIpcMessagePort.js:47:47

As for start and debug, qode seems to be missing. I tried to run npm i several times to no avail.

node:events:492
      throw er; // Unhandled 'error' event
      ^

Error: spawn /home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/@nodegui/qode/binaries/qode ENOENT
    at ChildProcess._handle.onexit (node:internal/child_process:286:19)

System Information

  • OS: Fedora 38
  • Node version: 20.5.1
  • NPM version: 10.3.0

Full Outputs

Show…
$ npm run dev

> [email protected] dev
> webpack --mode=development

node:internal/crypto/hash:69
  this[kHandle] = new _Hash(algorithm, xofLen);
                  ^

Error: error:0308010C:digital envelope routines::unsupported
    at new Hash (node:internal/crypto/hash:69:19)
    at Object.createHash (node:crypto:138:10)
    at BulkUpdateDecorator.hashFactory (/home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack/lib/util/createHash.js:144:18)
    at BulkUpdateDecorator.update (/home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack/lib/util/createHash.js:46:50)
    at OriginalSource.updateHash (/home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack-sources/lib/OriginalSource.js:104:8)
    at NormalModule._initBuildHash (/home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack/lib/NormalModule.js:753:17)
    at handleParseResult (/home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack/lib/NormalModule.js:817:10)
    at /home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack/lib/NormalModule.js:908:4
    at processResult (/home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack/lib/NormalModule.js:640:11)
    at /home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/webpack/lib/NormalModule.js:692:5 {
  opensslErrorStack: [ 'error:03000086:digital envelope routines::initialization error' ],
  library: 'digital envelope routines',
  reason: 'unsupported',
  code: 'ERR_OSSL_EVP_UNSUPPORTED'
}

Node.js v20.5.1

            triggerUncaughtException(err, true /* fromPromise */);
            ^

RpcIpcMessagePortClosedError: Cannot send the message - the message port has been closed for the process 31422.
    at /home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/fork-ts-checker-webpack-plugin/lib/rpc/rpc-ipc/RpcIpcMessagePort.js:47:47
    at process.processTicksAndRejections (node:internal/process/task_queues:81:21) {
  code: undefined,
  signal: undefined
}

npm run build prints the same output as npm run dev.

$ npm run start

> [email protected] start
> node livereload.js node_modules/.bin/qode ./dist/index.js

node:events:492
      throw er; // Unhandled 'error' event
      ^

Error: spawn /home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/@nodegui/qode/binaries/qode ENOENT
    at ChildProcess._handle.onexit (node:internal/child_process:286:19)
    at onErrorNT (node:internal/child_process:484:16)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
Emitted 'error' event on ChildProcess instance at:
    at ChildProcess._handle.onexit (node:internal/child_process:292:12)
    at onErrorNT (node:internal/child_process:484:16)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  errno: -2,
  code: 'ENOENT',
  syscall: 'spawn /home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/@nodegui/qode/binaries/qode',
  path: '/home/onegen/devel/experiments/svelte-nodegui-starter/node_modules/@nodegui/qode/binaries/qode',
  spawnargs: [ './dist/index.js' ]
}

Node.js v20.5.1

npm run debug output is same as npm run start.

ERROR in src/app.ts:4:15 TS2345: Argument of type 'typeof SvelteComponentDev' is not assignable to parameter of type 'typeof SvelteComponent'. Types of construct signatures are incompatible.

Hey!

I just cloned this repository and installed dependencies but when I tried to run npm run dev. I got this error message:

ERROR in src/app.ts:4:15
TS2345: Argument of type 'typeof SvelteComponentDev' is not assignable to parameter of type 'typeof SvelteComponent'.
  Types of construct signatures are incompatible.
    Type 'new (options: IComponentOptions<Record<string, any>>) => SvelteComponentDev' is not assignable to type 'new (options: { target?: NSVElement<NativeView<Component>> | Element; props?: any; anchor?: NSVElement<NativeView<Component>> | Element; intro?: boolean; }) => SvelteComponent'.
      Types of parameters 'options' and 'options' are incompatible.
        Type '{ target?: NSVElement<NativeView<Component>> | Element; props?: any; anchor?: NSVElement<NativeView<Component>> | Element; intro?: boolean; }' is not assignable to type 'IComponentOptions<Record<string, any>>'.
          Types of property 'target' are incompatible.
            Type 'NSVElement<NativeView<Component>> | Element' is not assignable to type 'Element | ShadowRoot'.
              Type 'NSVElement<NativeView<Component>>' is not assignable to type 'Element | ShadowRoot'.
                Type 'NSVElement<NativeView<Component>>' is missing the following properties from type 'Element': attributes, classList, className, clientHeight, and 139 more.

Hope there's a fix for that! Thanks

Error when running npm run dev or npm run build

I get this error when trying to run npm run dev or npm run build in the starter project:

ERROR in ./src/app.ts 1:0-56
Module not found: Error: Can't resolve '@nodegui/svelte-nodegui' in 'C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\src'
resolve '@nodegui/svelte-nodegui' in 'C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\src'
  Parsed request is a module
  using description file: C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\package.json (relative path: ./src)     
    resolve as module
      C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\src\node_modules doesn't exist or is not a directory        
      looking for modules in C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules
        single file module
          using description file: C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\package.json (relative path: ./node_modules/@nodegui/svelte-nodegui)
            no extension
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui is not a file  
            .ts
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.ts doesn't exist
            .mjs
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.mjs doesn't exist
            .js
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.js doesn't exist
            .svelte
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.svelte doesn't 
exist
            .scss
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.scss doesn't exist
            .css
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.css doesn't exist
            .json
              C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.json doesn't exist
        existing directory C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui   
          using description file: C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\package.json (relative path: .)
            using description file: C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\package.json (relative path: ./node_modules/@nodegui/svelte-nodegui)
              no extension
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui is not a file              .ts
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.ts doesn't exist
              .mjs
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.mjs doesn't exist
              .js
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.js doesn't exist
              .svelte
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.svelte doesn't exist
              .scss
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.scss doesn't 
exist
              .css
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.css doesn't exist
              .json
                C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui.json doesn't 
exist
              as directory
                existing directory C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui
                  using description file: C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\package.json (relative path: .)
                    using path: C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index
                      using description file: C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\package.json (relative path: ./index)
                        no extension
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index doesn't exist
                        .ts
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index.ts doesn't exist
                        .mjs
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index.mjs doesn't exist
                        .js
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index.js doesn't exist
                        .svelte
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index.svelte doesn't exist
                        .scss
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index.scss doesn't exist
                        .css
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index.css doesn't exist
                        .json
                          C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\svelte_nodegui_starter\node_modules\@nodegui\svelte-nodegui\index.json doesn't exist
      C:\Users\rieno\Documents\Svelte-Apps\test-nodegui\node_modules doesn't exist or is not a directory
      C:\Users\rieno\Documents\Svelte-Apps\node_modules doesn't exist or is not a directory
      C:\Users\rieno\Documents\node_modules doesn't exist or is not a directory
      looking for modules in C:\Users\rieno\node_modules
        single file module
          No description file found in C:\Users\rieno\node_modules\@nodegui or above
          no extension
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui doesn't exist
          .ts
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui.ts doesn't exist
          .mjs
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui.mjs doesn't exist
          .js
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui.js doesn't exist
          .svelte
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui.svelte doesn't exist
          .scss
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui.scss doesn't exist
          .css
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui.css doesn't exist
          .json
            C:\Users\rieno\node_modules\@nodegui\svelte-nodegui.json doesn't exist
        C:\Users\rieno\node_modules\@nodegui\svelte-nodegui doesn't exist
      C:\Users\node_modules doesn't exist or is not a directory
      C:\node_modules doesn't exist or is not a directory

webpack 5.24.2 compiled with 1 error in 2260 ms
ERROR in src/app.ts:1:31
TS2307: Cannot find module '@nodegui/svelte-nodegui' or its corresponding type declarations.
  > 1 | import { svelteNodeGUI } from "@nodegui/svelte-nodegui";
      |                               ^^^^^^^^^^^^^^^^^^^^^^^^^
    2 |
    3 | import App from "./App.svelte";
    4 | svelteNodeGUI(App, {});

Does anyone know how to fix this?

Type error in starter template

When I run the starter template I get a type error: TS2345: Argument of type 'typeof SvelteComponentDev' is not assignable to parameter of type 'typeof SvelteComponent'.

Steps I followed:

  • Clone this repo.
  • yarn
  • yarn dev

Complete error message:
image

What I tried:

  • Tried casting: svelteNodeGUI(App as SvelteComponent, {}); Did not work.

Any ideas how to fix this? I could not find anything relevant in the FAQ or previous issues.
Thank you for the awesome work you are doing.

GUI is messed up

Hi!

I followed the getting started guide and when I run the app it looks very bad.

Captura de Pantalla 2021-06-03 a la(s) 22 16 22

Cannot find module '@nodegui/svelte-nodegui' or its corresponding type declarations.

From the very scratch:
npx degit ....
npm run dev

[email protected] dev
webpack --mode=development

assets by status 58.1 KiB [cached] 1 asset
asset nodegui_core-71e80e7a0d4c8202eac6ca8d0e0c6d25.node 7.41 MiB [compared for emit] (auxiliary name: main)
asset index.js 1.39 MiB [compared for emit] (name: main) 1 related asset
runtime modules 21.9 KiB 10 modules
modules by path ./node_modules/@nodegui/nodegui/ 510 KiB 212 modules
modules by path ./node_modules/postcss/lib/.js 479 KiB 25 modules
modules by path ./node_modules/source-map/ 99.4 KiB 11 modules
modules by path ./src/ 10.8 KiB
modules by path ./src/components/ 6.85 KiB 3 modules
2 modules
modules by path ./node_modules/cuid/ 2.88 KiB 4 modules
modules by path ./node_modules/webpack/hot/
.js 3.75 KiB 3 modules
modules by path ./node_modules/chalk/ 12.1 KiB 3 modules
modules by path ./node_modules/color-convert/*.js 20.3 KiB 3 modules
modules by path ./node_modules/svelte/ 54.1 KiB
./node_modules/svelte/internal/index.mjs 53.9 KiB [built] [code generated]
./node_modules/svelte/index.mjs 212 bytes [built] [code generated]
18 modules

ERROR in ./src/app.ts 1:0-56
Module not found: Error: Can't resolve '@nodegui/svelte-nodegui' in '/home/michael/d-nodegui/sns/src'

...

etc

what does this mean?

what should be done?

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.