Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

License

NotificationsYou must be signed in to change notification settings

nishant/stock-desktop

Repository files navigation

MaintainedMake a pull requestLicense

Linux BuildMacOS BuildWindows Build


LogoLogo

Yahoo Finance Desktop Client

A desktop client to query stock data from Yahoo Finance.

Bootstrapped and packaged with Angular 11 and Electron 12.


Report Bug ·Request Feature



Table of Contents

Introduction

A desktop client to query stock data from Yahoo Finance, bootstrapped andpackaged with Angular 11 and Electron 12.

Currently runs with:

  • Angular v11
  • Electron v12
  • Electron Builder v22

This application can be:

  • Run in a local development environment with Electron & Hot reload
    • Hot reload only pertains to the renderer process. The main electron processis not able to be hot reloaded, only restarted.
  • Run in a production environment
  • Packaged into an executable for Linux, Windows & Mac

Note:Angular 11.x CLI needs Node 10.13 or later to work correctly.


Getting Started

Clone this repository locally:

git clone https://github.com/nishant/stock-desktop.git

Install dependencies with npm:

npm install

There is an issue withyarn andnode_modules when the application is builtby the packager. Usenpm as dependencies manager.

If you want to generate Angular components with Angular CLI , youMUSTinstall@angular/cli in npm global context. Follow Angular'sdocumentation if you had installed aprevious version ofangular-cli.

npm install -g @angular/cli

Building for Development

Run the start script to use the application local development environment withhot reload.

npm start

The application code is managed bymain.ts. The app runs with a simple AngularApp (http://localhost:4200) and an Electron window.

You can disable "Developer Tools" by setting the boolean flagopenDevTools tofalse inmain.ts.


Running in Browser Mode

To execute the application in the browser with hot reload, runnpm run ng:serve:web.

Alternatively, the application can still run in-browser athttps://localhost:4200 even whennpm start is used.


Using Electron / NodeJS Libraries

This project runs in both web and desktop mode. To make this work,you have toimport your dependencies the right way.

Checkproviders/electron.service.ts to see how to conditionally importlibraries when using electron / NodeJS / 3rd party libraries in renderer context(i.e. Angular).


Using Third Party Libraries (Material, Bootstrap, etc)

3rd party libraries used in electron's renderer process (like angular material)have to be added indevDependencies ofpackage.json.

They are already added in the final package during webpack's compilation phase.Otherwise, it will significantly increase the size of your final package.


Using Specific Libraries in Electron Main Thread (rxjs, ngrx, etc)

Import your library in npm dependencies section (not devDependencies) withnpm install --save.

It will be loaded by electron during the build phase and added to your finalpackage.

Use your library by importing it inmain.ts.


Included Commands

CommandDescription
npm run startExecute the app in the desktop and browser
npm run ng:serveExecute the app in the browser
npm run buildBuild the app. Built files are located in the /dist folder
npm run build:devBuild the app for the development environment. Built files are located in the /dist folder
npm run build:prodBuild the app for the production environment with Angular AOT. Built files are located in the /dist folder
npm run electron:localBuilds your application and start electron
npm run electron:buildBuilds your application and creates an app consumable based on your operating system
npm run testExecute the unit tests
npm run e2eExecute the end-to-end tests
npm run lintRun the linter

The application is optimized. Only the /dist folder and node dependencies areincluded in the executable.


Roadmap

See theopen issues for alist of proposed features and known issues.


Contributing

If you have any feature ideas, feel free to contribute by following these steps.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/MyAwesomeFeature)
  3. Commit your Changes (git commit -m 'Added MyAwesomeFeature')
  4. Push to the Branch (git push origin feature/MyAwesomeFeature)
  5. Open a Pull Request



About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

[8]ページ先頭

©2009-2025 Movatter.jp