Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(template-typescript): use main script to start app #1345

Merged
merged 2 commits into from
Dec 14, 2019

Conversation

codebytere
Copy link
Member

  • I have read the contribution documentation for this project.
  • I agree to follow the code of conduct that this project follows, as appropriate.
  • The testsuite passes successfully on my local machine (if applicable).

Summarize your changes:

Fixes up the scripts to set main in package.json to dist instead of baking it into the start script.

@malept malept changed the title chore: don't start from dist chore(template-typescript): don't start from dist Dec 13, 2019
@codecov
Copy link

codecov bot commented Dec 13, 2019

Codecov Report

Merging #1345 into master will increase coverage by 28.12%.
The diff coverage is 100%.

Impacted file tree graph

@@             Coverage Diff             @@
##           master    #1345       +/-   ##
===========================================
+ Coverage   40.43%   68.56%   +28.12%     
===========================================
  Files           4       70       +66     
  Lines         183     2042     +1859     
  Branches       37      383      +346     
===========================================
+ Hits           74     1400     +1326     
- Misses         96      459      +363     
- Partials       13      183      +170
Impacted Files Coverage Δ
...ages/template/typescript/src/TypeScriptTemplate.ts 100% <100%> (ø)
packages/maker/snap/src/MakerSnap.ts 100% <0%> (ø)
...es/api/core/src/api/init-scripts/init-directory.ts 93.75% <0%> (ø)
packages/api/core/src/util/index.ts 100% <0%> (ø)
packages/api/core/src/util/publish-state.ts 85.36% <0%> (ø)
packages/utils/async-ora/src/index.ts 100% <0%> (ø)
packages/maker/wix/src/util/author-name.ts 90% <0%> (ø)
packages/plugin/webpack/src/WebpackPlugin.ts 34.85% <0%> (ø)
packages/maker/rpm/src/MakerRpm.ts 94.73% <0%> (ø)
packages/installer/base/src/Installer.ts 75% <0%> (ø)
... and 58 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update abbf031...f8af756. Read the comment docs.

Copy link
Member

@malept malept left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit: I'll merge when tests pass.

@malept malept changed the title chore(template-typescript): don't start from dist chore(template-typescript): use main script to start app Dec 14, 2019
@malept malept changed the title chore(template-typescript): use main script to start app refactor(template-typescript): use main script to start app Dec 14, 2019
@malept malept merged commit ef0b2ba into master Dec 14, 2019
@malept malept deleted the fix-start-scripts branch December 14, 2019 03:35
@mayeths
Copy link

mayeths commented Dec 15, 2019

Hey I'm new to electron, and want to figure out how to develop my first electron app using typescript and webpack. Your PR is exactly what I need (thanks!). I tried electron-webpack before but it's hard to write my webpack config since they hide everything so deeply.

Now I use your template to init a empty project, but get stuck with --template=typescript-webpack and --template=typescript arguments. I tried the following steps:

$ yarn create electron-app my-first-electron-app --template=typescript

× Locating custom template: "typescript"
An unhandled error has occurred inside Forge:
Failed to locate custom template: "typescript"
.........

It's failed. Then I see this pull request and try:

$ npm i -g @electron-forge/cli

.........
+ @electron-forge/cli@6.0.0-beta.46
$ electron-forge init my-second-electron-app --template=typescript-webpack

× Locating custom template: "typescript-webpack"
Failed to locate custom template: "typescript-webpack"
Try `npm install -g @electron-forge-template-typescript-webpack`
Error: Failed to locate custom template: "typescript-webpack"
.........

It's also failed. Finally I try typescript template with CLI:

$ electron-forge init my-third-electron-app --template=typescript

√ Checking your system
......... Everything ok here
√ Installing Template Dependencies

It passed. But I can't see anything about typescript in it. The folder looks like this:

electron-forge


Did I make any mistakes? Or maybe it means I should wait until the template release...

electron-forge is awesome. Thanks a million.

@malept
Copy link
Member

malept commented Dec 18, 2019

This template has been released in beta 47, published a few seconds ago.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants