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

Feature/docusaurus #2625

Closed
wants to merge 32 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
d96deef
initial experiment.
ckniffen Jul 6, 2023
a63ccef
feat: bump typescript to 5.x (#2387)
ckniffen Jul 18, 2023
351d66b
feat: remove node 14 support (#2386)
ckniffen Jul 20, 2023
b1ac7be
feat: remove `lodash` as a dependency (#2378)
ckniffen Jul 25, 2023
b4061b3
feat: remove `decimal.js` and `big-integer` (#2379)
ckniffen Jul 26, 2023
92b22dd
feat(deps): make `https-proxy-agent` optional (#2388)
ckniffen Jul 26, 2023
6ca089d
feat: remove 3 http related polyfills (#2375)
ckniffen Jul 26, 2023
7164415
feat(deps): remove `assert-browserify` (#2389)
ckniffen Jul 26, 2023
12175e5
feat: remove `BroadcastClient` (#2408)
ckniffen Jul 27, 2023
5845482
BREAKING CHANGE(fix): `deriveKeypair` ignoring a manual `algorithm` b…
JST5000 Aug 8, 2023
75fdbcc
fix: Fix invariant assertion in binary-codec (#2429)
JST5000 Aug 9, 2023
5f6923e
test: remove extra polyfills only for testing (#2428)
ckniffen Aug 12, 2023
528b17e
fix: make docs not output confusing information in xrpl client (#2337)
justinr1234 Aug 15, 2023
a38354d
edit tutorial page + footer + styles
jonathanlei Aug 17, 2023
8b74827
add docsearch
jonathanlei Aug 17, 2023
651d5c1
feat: remove `util` polyfill and fix `HISTORY.md` (#2432)
ckniffen Aug 21, 2023
d33cdb4
Re-add the `walletFromSecretNumbers` custom algorithm test (#2437)
JST5000 Aug 21, 2023
fdecff5
Turn off minimal mode
ckniffen Aug 24, 2023
40f65ae
changes from docs team
jonathanlei Aug 24, 2023
d130c97
Merge branch 'feature/docusaurus' of github.com:XRPLF/xrpl.js into fe…
jonathanlei Aug 24, 2023
7101dc8
initial experiment.
ckniffen Jul 6, 2023
273a11f
edit tutorial page + footer + styles
jonathanlei Aug 17, 2023
e48dd0b
add docsearch
jonathanlei Aug 17, 2023
fa1d45c
changes from docs team
jonathanlei Aug 24, 2023
bf70a02
Turn off minimal mode
ckniffen Aug 24, 2023
f94d116
Merge branch 'feature/docusaurus' of github.com:XRPLF/xrpl.js into fe…
jonathanlei Sep 26, 2023
14dcaf9
frontpage darkmode done
jonathanlei Jan 22, 2024
25945e6
upright arrows + color
jonathanlei Jan 25, 2024
d3c2882
add images/logos, fix light mode
jonathanlei Jan 25, 2024
436099e
align items
jonathanlei Jan 25, 2024
0af5217
add updated fonts - files
jonathanlei Jan 31, 2024
66d1bd7
change config
jonathanlei Jan 31, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/nodejs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ jobs:

strategy:
matrix:
node-version: [14.x, 16.x, 18.x, 20.x]
node-version: [16.x, 18.x, 20.x]

steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -98,7 +98,7 @@ jobs:

strategy:
matrix:
node-version: [14.x, 16.x, 18.x, 20.x]
node-version: [16.x, 18.x, 20.x]

steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -202,7 +202,7 @@ jobs:

strategy:
matrix:
node-version: [14.x, 16.x, 18.x, 20.x]
node-version: [16.x, 18.x, 20.x]

steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .nvmrc
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v14
v16
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@ See the full reference documentation for all classes, methods, and utilities.
4. Subscribing to changes in the ledger ([Ex. ledger, transactions, & more...](https://xrpl.org/subscribe.html))
5. Parsing ledger data into more convenient formats ([`xrpToDrops`](https://js.xrpl.org/functions/xrpToDrops.html) and [`rippleTimeToISOTime`](https://js.xrpl.org/functions/rippleTimeToISOTime.html))

All of which works in Node.js (tested for v14+) & web browsers (tested for Chrome).
All of which works in Node.js (tested for v16+) & web browsers (tested for Chrome).

# Quickstart

### Requirements

+ **[Node.js v16](https://nodejs.org/)** is recommended. We also support v14, v18 and v20. Other versions may work but are not frequently tested.
+ **[Node.js v16](https://nodejs.org/)** is recommended. We also support v18 and v20. Other versions may work but are not frequently tested.

### Installing xrpl.js

Expand Down
28 changes: 4 additions & 24 deletions UNIQUE_SETUPS.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,10 @@ To use `xrpl.js` with React, you need to install shims for core NodeJS modules.

```shell
npm install --save-dev \
assert \
buffer \
crypto-browserify \
https-browserify \
os-browserify \
process \
stream-browserify \
stream-http \
url
stream-browserify
```

2. Modify your webpack configuration
Expand All @@ -46,13 +41,8 @@ To use `xrpl.js` with React, you need to install shims for core NodeJS modules.
module.exports = function override(config) {
const fallback = config.resolve.fallback || {};
Object.assign(fallback, {
assert: require.resolve("assert"),
crypto: require.resolve("crypto-browserify"),
http: require.resolve("stream-http"),
https: require.resolve("https-browserify"),
os: require.resolve("os-browserify"),
stream: require.resolve("stream-browserify"),
url: require.resolve("url"),
ws: require.resolve("xrpl/dist/npm/client/WSWrapper"),
});
config.resolve.fallback = fallback;
Expand All @@ -62,12 +52,7 @@ To use `xrpl.js` with React, you need to install shims for core NodeJS modules.
Buffer: ["buffer", "Buffer"],
}),
]);

// This is deprecated in webpack 5 but alias false does not seem to work
config.module.rules.push({
test: /node_modules[\\\/]https-proxy-agent[\\\/]/,
use: "null-loader",
});

return config;
};
```
Expand Down Expand Up @@ -132,7 +117,7 @@ Similar to above, to get xrpl.js to work with Vite you need to set up a couple a

2. Copy these settings into your `vite.config.ts` file.

```
```javascript
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import { NodeGlobalsPolyfillPlugin } from "@esbuild-plugins/node-globals-polyfill";
Expand All @@ -146,7 +131,6 @@ export default defineConfig({
},
optimizeDeps: {
esbuildOptions: {

define: {
global: 'globalThis',
},
Expand All @@ -170,24 +154,20 @@ resolve: {
events: 'events',
crypto: 'crypto-browserify',
stream: 'stream-browserify',
http: 'stream-http',
https: 'https-browserify',
ws: 'xrpl/dist/npm/client/WSWrapper',
},
}})
```

3. Install the config dependencies and xrpl (e.g. using this command)

```
```shell
npm install --save-dev @esbuild-plugins/node-globals-polyfill \
rollup-plugin-polyfill-node \
&& npm install
events \
crypto-browserify \
stream-browserify \
stream-http \
https-browserify \
xrpl
```

Expand Down
Loading