nodegui / nodegui-starter

A starter repo for NodeGui projects
123 stars 32 forks source link

A more concise sample app would be easier to follow #2

Open Autre31415 opened 5 years ago

Autre31415 commented 5 years ago

As a big fan of Electron I became very curious about nodegui and really think this tech is promising.

I'm currently working on converting a small electron project over to this framework to compare the differences in performances and developer workflow, and starting from the beginning I encountered this sample app linked in the hello world documentation.

My issue with this repo however is how much extra developer dependencies are packed into it. It makes a lot of assumptions about dev environment (TS, webpack config, etc) which made it difficult to grok which layers were initially nodegui specific or not. I spent some time trimming it down to the bare minimum that nodegui requires which resulted in only that single dependency, and at that point it became much more useful.

Based on that experience my suggestion would be pare this sample app down to be much simpler, in the style of the electron quick start sample app.

a7ul commented 5 years ago

Hi @Autre31415 Thanks for the feedback. Could you post your final result here?

Autre31415 commented 5 years ago

Here's a sample repo

a7ul commented 5 years ago

The only issue I see for this sample repo is that it doesnt allow for easier app packaging since there is no javascript bundle generated. If we have a solution for it then it looks good @Autre31415

Autre31415 commented 5 years ago

Presumably you'd want the actual JS bundling to happen within the context of a standalone app packager module that is generating the binaries.

a7ul commented 5 years ago

@Autre31415 Yeah makes sense. Thank you.

I feel that there are more urgent issues that I need to focus on at the moment hence I wont be able to look at this specifically for some time. But if you have some time could you help out with this ?

Specifically, I am looking at moving the actual webpack bundling to the @nodegui/packer like you mentioned or maybe build something like react-scripts like in the case of create-react-app. What are your thoughts?

Autre31415 commented 5 years ago

I'd start with moving this webpack config over to the packer module if it's not there already and exposing a simple cli to get the bundle entry point.