google-finance-quote 4.0.0-dev.0 → 4.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +10 -3
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -2,14 +2,21 @@
2
2
 
3
3
  Node Google Finance API wrapper for free.
4
4
  No API key is required!
5
- > Note: This results may vary by up to 20 minutes.
6
- > Note: `3.0.0 <= x` doesn't support proxies.
5
+
6
+ > ![Note]
7
+ > This results may vary by up to 20 minutes.
8
+
9
+ > ![Note]
10
+ > `3.0.0 <= x` doesn't support proxies.
7
11
 
8
12
  ## Usage
9
13
 
10
14
  ### Get Started
11
15
 
12
16
  ```js
17
+ // ESM
18
+ import { Finance, symbols, currencyCodesSymbols, cryptoCurrencyCodesSymbols } from "google-finance-quote";
19
+ // CJS
13
20
  const { Finance, symbols, currencyCodesSymbols, cryptoCurrencyCodesSymbols } = require("google-finance-quote");
14
21
 
15
22
  console.log(symbols); // Returns available symbols.
@@ -19,7 +26,7 @@ console.log(cryptoCurrencyCodesSymbols); // Returns available crypto currency co
19
26
  const finance = new Finance(); // You can use this: new Finance({ from 'USD', to: 'JPY' });
20
27
 
21
28
  finance
22
- .setFrom('USD');
29
+ .setFrom('USD')
23
30
  .setTo('JPY');
24
31
 
25
32
  (async () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "google-finance-quote",
3
- "version": "4.0.0-dev.0",
3
+ "version": "4.0.0",
4
4
  "description": "Node Google Finance API wrapper for free. No API key is required!",
5
5
  "main": "dist/cjs/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -16,7 +16,7 @@
16
16
  "build:esm": "tsc -p tsconfig.esm.json",
17
17
  "build:post": "node ./build/copy-types.js && node ./build/rename-esm.js",
18
18
  "build": "npm run build:cjs && npm run build:esm && npm run build:post",
19
- "prepare": "npm run build",
19
+ "prepublishOnly": "npm run build",
20
20
  "test": "echo \"Error: no test specified\" && exit 1",
21
21
  "format": "prettier --write ./src/ ./build/"
22
22
  },