1.0.14 • Published 2 years ago

travis-weather-app v1.0.14

Weekly downloads
-
License
-
Repository
-
Last release
2 years ago

Warnings

  • I have not setup a backend for this app. The Open Weather API key shouldn't be stored the way it is in utilities.ts. I'd recommend setting up your own server to fetch the API weather and return it.

Setup

  1. Get an API key from Open Weather and add it to utilities.js
  2. npm install
  3. To run locally: npm run compile && npm run cli

How to deploy an NPM App

  1. Add the following to your package JSON
  "name": "your-app-name",
  "version": "1.0.0",
  "bin": {
    "the-command-to-run-in-the-cli": "./dist/cli.js"
  },
  1. Add #!/usr/bin/env node to your app entrypoint so the CLI runs it as node and not a bash script
  2. Deploy to NPM (After creating an account)

npm run compile && npm publish

npm i -g your-app-name

the-command-to-run-in-the-cli

Notes

  • When redeploying, you'll need to increment the version.
  • Sometimes deployment fails and you'll need to deploy a new version
  • I made a mess of things trying to get TypeScript and Webpack configured correctly. This is why npm run addShebang exists.
1.0.14

2 years ago

1.0.13

2 years ago

1.0.12

2 years ago

1.0.11

2 years ago

1.0.10

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago