Commit Graph

226 Commits

Author SHA1 Message Date
Franck Royer 98c93c8283
Upgrade libp2p, peer-id, multiaddr
Use new packages and fix most compilation errors.
Remaining error to be dealt with in waku.ts.
2022-07-20 12:40:37 +10:00
Franck Royer 0cec093a4d
chore!: upgrade dns-query 2022-07-19 16:31:21 +10:00
Franck Royer 1fcf84b348
Fix size-limit 2022-06-20 14:32:22 +10:00
Franck Royer 3dde86fcb7
Revert to webpack for UMD 2022-06-20 14:32:22 +10:00
Franck Royer 7432aaca25
Add `main` and `module` properties 2022-06-20 14:32:22 +10:00
Franck Royer e3b6292a6e
Use rollup instead of tsc to generate cjs files 2022-06-20 14:32:22 +10:00
Franck Royer ebbb0a2713
Re-introduce cjs build 2022-06-20 14:32:22 +10:00
Franck Royer 7ea98c1af0
Script to add js extension to esm files 2022-06-20 14:32:21 +10:00
Franck Royer 58006e1e38
Include root source files 2022-06-20 14:32:21 +10:00
Franck Royer 43580dd093
Add types export 2022-06-20 14:32:21 +10:00
Franck Royer 792c84ec31
Fix exports field 2022-06-20 14:32:21 +10:00
Franck Royer c4758a8737
Setup rollup, move files to dist/ 2022-06-20 14:32:20 +10:00
Franck Royer 82aba32f9e
Migrate from ts-proto to protons
The latter does not bring Buffer/Long and is ESM compatible.
2022-06-20 14:32:20 +10:00
Franck Royer 75d2cf1113
Fix size-limit 2022-06-20 14:32:20 +10:00
Franck Royer 35a4cba37a
Include src files in package
To remove source map warning
2022-06-20 14:32:20 +10:00
Franck Royer 4352cb923d
Replace karma-env-preproc with webpack 2022-06-20 14:32:20 +10:00
Franck Royer cb10ca16d1
Migrate package to ESM 2022-06-20 14:32:20 +10:00
Franck Royer 04fbc55fdf
Use `npm ci` in CI
So there is no attempt to update the lock file.
2022-06-17 16:30:03 +10:00
Franck Royer 1a53a35358
Release 0.24.0 2022-05-27 23:46:18 +10:00
Franck Royer ec10dcd0ad
Add `prepublish` script 2022-05-27 23:38:12 +10:00
Franck Royer 7b54dd1b59
Run build in parallel
They use to have intra-dependencies but not the case anymore.
2022-05-27 23:29:28 +10:00
Franck Royer 5baf42c76e
Remove `build:dev`
This is a type check, already done with `test:tsc`
2022-05-27 23:29:27 +10:00
Franck Royer 354ca4e7b5
Delete build folder before building 2022-05-27 23:24:04 +10:00
Franck Royer c66927668b
Run tsc as part of test script instead of building 2022-05-20 10:32:43 +10:00
Franck Royer 7d9406bcfc
Release 0.23.0 2022-05-19 15:36:24 +10:00
Franck Royer 1d8e3837ea
Replace deprecated `multihashes` with `multiformats` 2022-05-19 15:17:16 +10:00
Franck Royer 48efcc1562
Add all used deps 2022-05-18 20:41:10 +10:00
Franck Royer b708077483
Remove assert usage 2022-05-13 17:28:38 +10:00
Franck Royer 920668c54c
Release 0.22.0 2022-05-10 16:44:17 +10:00
Franck Royer 00be6b147d
Remove crypto-browserify 2022-05-09 23:32:43 +10:00
Franck Royer 556e060335
Replace `secp256k1` with `@noble/secp256k1` 2022-05-09 23:10:15 +10:00
Franck Royer fd15b190d5
Release 0.21.0 2022-05-05 16:45:55 +10:00
Franck Royer dee587d644
Remove unneeded dev dep 2022-05-02 16:37:27 +10:00
Franck Royer 882ddac94e
Run prettier on GitHub workflows 2022-05-02 16:37:25 +10:00
Franck Royer 929f05968b
Release 0.20.0 2022-03-30 10:14:25 +11:00
Franck Royer 13d12f8284
Froze `libp2p-gossipsub` version to 0.13.0
0.13.2 moved heartbeat class which is a breaking change.
2022-03-29 21:28:03 +11:00
Franck Royer 483b11723c
Release 0.19.2 2022-03-21 10:36:27 +11:00
Dylan Oliver 565ffb18fb
fix package.json exports to work in node as well as browser 2022-03-18 14:41:23 +11:00
Franck R ac337855aa
Release 0.19.1 (#610) 2022-03-10 16:25:51 +11:00
Franck R e4024d5c72
Release 0.19.0 (#607) 2022-03-09 14:29:35 +11:00
Franck R 2798376776
Remove ecies-geth (#598)
* test: specify encryption method

Makes debugging easier.

* Fix log typo

* Remove ecies-geth

Start removal of elliptic dependency and move towards exclusive usage to
CryptoSubtle.
2022-03-06 23:20:59 +11:00
Franck Royer fe30449861
Add exports field for node
While this library targets the browser, it is sometimes helpful to use
it in need for experiments.
For example: https://github.com/status-im/js-waku/pull/588
2022-03-04 14:49:33 +11:00
Franck Royer 8029200984
Get eslint to fix files in precommit git hook
We need the hook to fix things when possible.
2022-03-01 17:04:03 +11:00
Franck Royer 0bbefe70f3
Add git hook to format & lint file 2022-02-25 14:18:46 +11:00
Franck R d838f53c78
Release 0.18.0 (#576) 2022-02-24 16:40:14 +11:00
Franck R a488988f37
Implement Waku Store 2.0.0-beta4 (#566) 2022-02-24 16:25:58 +11:00
jemboh da52903357
Angular js example for relay best practices (#549)
Co-authored-by: Franck Royer <franck@status.im>
2022-02-22 14:02:08 +11:00
Franck R 64657a250f
Replace rlp with ethers' rlp (#526) 2022-02-16 14:08:48 +11:00
Franck R 297d65ce03
Reduce Buffer usage in ENR module (#522) 2022-02-16 12:11:54 +11:00
Franck R 9931011c93
Release 0.17.0 (#538) 2022-02-16 11:55:53 +11:00
Franck R 30faaf91d3
Add size-limit (#536) 2022-02-16 11:13:18 +11:00
Franck R 2dc8764be2
Remove axios (#520) 2022-02-14 09:26:22 +11:00
Franck R 0f678750df
Improve docs (#519) 2022-02-11 17:27:15 +11:00
Franck R 4c80f7f0df
Remove odd prettier config (#500) 2022-02-04 14:12:00 +11:00
Franck R 91d6e436d4
Do not run bootstrap live data test as part of normal CI (#468) 2022-02-03 16:58:53 +11:00
dependabot[bot] ce9609a376
Bump @types/mocha from 8.2.2 to 9.1.0 (#486)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-03 15:57:36 +11:00
Franck R 69f0005445
Bump libp2p from 0.32.4 to 0.36.2, libp2p-gossipsub from 0.12.1 to 0.13.0 (#470)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-02-02 15:12:08 +11:00
Jakub e4888f779c
ci: build examples and deply in a subfolder (#432) 2022-02-02 11:35:28 +11:00
Franck R b257885204
test: Fix flackiness (#474) 2022-02-01 12:54:54 +11:00
Franck R 4be3d95535
Release 0.16.0 (#473) 2022-01-31 15:56:59 +11:00
Franck R f44d700c11
Do not run bootstrap live data test as part of normal CI (#450) 2022-01-27 21:50:27 +11:00
Franck R 6cb2b6615b
Update to latest typescript (#438) 2022-01-27 15:25:17 +11:00
Jakub 671c757fa2
ci: add Jenkinsfile for building docs page (#410)
CI setup that builds the `master` branch and pushes it to `gh-pages`
branch in the repo which is published by GitHub pages.

Signed-off-by: Jakub Sokołowski <jakub@status.im>
2022-01-24 11:53:45 +01:00
Franck R 34e4cbba73
Use websocket instead of tcp in interop tests (#418) 2022-01-20 13:00:58 +11:00
Franck R 8b06b6e1d5
Release 0.15.0 (#414) 2022-01-19 12:24:32 +11:00
Franck Royer 2c16f0befb
Separate tests that use DNS data in CI 2022-01-14 12:44:06 +11:00
Franck Royer 0bfe9c9a64
Do not run command on js-waku lib when running examples scripts
This was happening when `d=./examples/README.md`.
2022-01-13 16:40:11 +11:00
Franck Royer e47335f4c0
Implement DNS Discovery and ENR tree 2022-01-13 15:38:22 +11:00
dependabot[bot] 2bc4582765
Bump libp2p-bootstrap from 0.13.0 to 0.14.0
Bumps [libp2p-bootstrap](https://github.com/libp2p/js-libp2p-bootstrap) from 0.13.0 to 0.14.0.
- [Release notes](https://github.com/libp2p/js-libp2p-bootstrap/releases)
- [Changelog](https://github.com/libp2p/js-libp2p-bootstrap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/libp2p/js-libp2p-bootstrap/compare/v0.13.0...v0.14.0)

---
updated-dependencies:
- dependency-name: libp2p-bootstrap
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-10 04:49:57 +00:00
dependabot[bot] 8f4e94e2b1
Bump ts-node from 9.1.1 to 10.4.0
Bumps [ts-node](https://github.com/TypeStrong/ts-node) from 9.1.1 to 10.4.0.
- [Release notes](https://github.com/TypeStrong/ts-node/releases)
- [Commits](https://github.com/TypeStrong/ts-node/compare/v9.1.1...v10.4.0)

---
updated-dependencies:
- dependency-name: ts-node
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-10 02:43:23 +00:00
Franck Royer ddec271621
Make minimum support node version 16
A number of libp2p packages do not support node 14 anymore.
2022-01-06 14:17:17 +11:00
dependabot[bot] 75b7341d2c
Bump cspell from 4.2.8 to 5.14.0
Bumps [cspell](https://github.com/streetsidesoftware/cspell) from 4.2.8 to 5.14.0.
- [Release notes](https://github.com/streetsidesoftware/cspell/releases)
- [Changelog](https://github.com/streetsidesoftware/cspell/blob/main/CHANGELOG.md)
- [Commits](https://github.com/streetsidesoftware/cspell/compare/cspell@4.2.8...v5.14.0)

---
updated-dependencies:
- dependency-name: cspell
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-04 17:32:19 +11:00
dependabot[bot] 6e436ee4e2
Bump @chainsafe/libp2p-noise from 4.1.1 to 5.0.0
Bumps [@chainsafe/libp2p-noise](https://github.com/ChainSafe/js-libp2p-noise) from 4.1.1 to 5.0.0.
- [Release notes](https://github.com/ChainSafe/js-libp2p-noise/releases)
- [Changelog](https://github.com/ChainSafe/js-libp2p-noise/blob/master/CHANGELOG.md)
- [Commits](https://github.com/ChainSafe/js-libp2p-noise/compare/v4.1.1...v5.0.0)

---
updated-dependencies:
- dependency-name: "@chainsafe/libp2p-noise"
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-04 02:54:41 +00:00
dependabot[bot] fd38545659
Bump puppeteer from 10.1.0 to 13.0.1
Bumps [puppeteer](https://github.com/puppeteer/puppeteer) from 10.1.0 to 13.0.1.
- [Release notes](https://github.com/puppeteer/puppeteer/releases)
- [Changelog](https://github.com/puppeteer/puppeteer/blob/main/CHANGELOG.md)
- [Commits](https://github.com/puppeteer/puppeteer/compare/v10.1.0...v13.0.1)

---
updated-dependencies:
- dependency-name: puppeteer
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-03 23:20:32 +00:00
dependabot[bot] 5bf25dfb76
Bump @types/node from 14.17.3 to 17.0.6
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 14.17.3 to 17.0.6.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-03 01:34:22 +00:00
dependabot[bot] 525c0121b3
Bump mocha from 8.4.0 to 9.1.3
Bumps [mocha](https://github.com/mochajs/mocha) from 8.4.0 to 9.1.3.
- [Release notes](https://github.com/mochajs/mocha/releases)
- [Changelog](https://github.com/mochajs/mocha/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mochajs/mocha/compare/v8.4.0...v9.1.3)

---
updated-dependencies:
- dependency-name: mocha
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-02 22:47:14 +00:00
Franck 068325244d
Update all eslint plugins 2022-01-03 09:29:10 +11:00
dependabot[bot] 57292f79de
Bump eslint from 7.29.0 to 8.6.0
Bumps [eslint](https://github.com/eslint/eslint) from 7.29.0 to 8.6.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/eslint/eslint/compare/v7.29.0...v8.6.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-03 09:29:10 +11:00
dependabot[bot] 01d605a292
Bump libp2p-gossipsub from 0.11.1 to 0.12.1
Bumps [libp2p-gossipsub](https://github.com/ChainSafe/js-libp2p-gossipsub) from 0.11.1 to 0.12.1.
- [Release notes](https://github.com/ChainSafe/js-libp2p-gossipsub/releases)
- [Changelog](https://github.com/ChainSafe/js-libp2p-gossipsub/blob/master/CHANGELOG.md)
- [Commits](https://github.com/ChainSafe/js-libp2p-gossipsub/compare/v0.11.1...v0.12.1)

---
updated-dependencies:
- dependency-name: libp2p-gossipsub
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-01-02 15:11:19 +00:00
Franck cf025dea82
Adjust eslint settings
See: https://github.com/prettier/eslint-config-prettier/blob/main/CHANGELOG.md#version-800-2021-02-21
2021-12-21 12:08:16 +11:00
dependabot[bot] 7b2866c0d5
Bump eslint-config-prettier from 6.15.0 to 8.3.0
Bumps [eslint-config-prettier](https://github.com/prettier/eslint-config-prettier) from 6.15.0 to 8.3.0.
- [Release notes](https://github.com/prettier/eslint-config-prettier/releases)
- [Changelog](https://github.com/prettier/eslint-config-prettier/blob/main/CHANGELOG.md)
- [Commits](https://github.com/prettier/eslint-config-prettier/compare/v6.15.0...v8.3.0)

---
updated-dependencies:
- dependency-name: eslint-config-prettier
  dependency-type: direct:development
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2021-12-21 12:08:16 +11:00
F 01c66f7e89
Add ENR with multiaddr
Imported from https://github.com/D4nte/discv5/pull/1
Replaced bcrypto backend with secp256k1.
2021-12-06 14:29:08 +11:00
F 235a05921b
Update typedoc deps
Needed to use markdown plugin in docs website.
2021-12-02 22:18:07 +11:00
F 31325bb673
Release 0.14.2
### Changed

- Examples: JS examples uses local ESM folder to replicate behaviour of
js-waku publish package.

### Fixed

- `TypeError` issue related to constructors using js-waku in a JS
project
  ([#323](https://github.com/status-im/js-waku/issues/323)).
2021-11-30 11:33:30 +11:00
F de9b313b65
Use es6/es2015 target for ESM output
es5 does not support class constructors and hence lead to issues.
2021-11-26 21:23:50 +11:00
Franck Royer 0cf12f3b55
Release 0.14.1
### Fixed
- Issue when importing the `utils` module.
2021-10-22 14:40:38 +11:00
Franck Royer 5009792fca
Remove exports field
TypeScript does not play nice with it just yet:
https://github.com/microsoft/TypeScript/issues/33079
2021-10-19 15:22:38 +11:00
Franck Royer 2c1ff58f93
Release 0.14.0
### Added
- If the `callback` function passed to`WakuStore.queryHistory` returns
  `true`, then no further pages are retrieved from the store.
- Use webpack to build UMD bundle of the library, see
  [README](./README.md) for usage.

### Changed
- **Breaking**: Renamed `WakuStore.QueryOptions`'s `direction` to
  `pageDirection` (and its type) as it only affects the page ordering,
  not the ordering of messages with the page.

### Fixed
- Docs: Ensure that `WakuStore`'s `QueryOptions` documentation is
  available [online](https://status-im.github.io/js-waku/docs/).
2021-10-13 11:14:40 +11:00
Franck Royer 7e22d4cb76
Release Candidate 0.14.0-rc.0
### Added
- If the `callback` function passed to`WakuStore.queryHistory` returns
  `true`, then no further pages are retrieved from the store.
- Use webpack to build UMD bundle of the library.

### Changed
- **Breaking**: Renamed `WakuStore.QueryOptions`'s `direction` to
  `pageDirection` (and its type) as it only affects the page ordering,
  not the ordering of messages with the page.

### Fixed
- Docs: Ensure that `WakuStore`'s `QueryOptions` documentation is
  available [online](https://status-im.github.io/js-waku/docs/).
2021-10-12 14:23:41 +11:00
Franck Royer b268f59c2e
Include ESM and UMD files in package 2021-10-12 12:01:14 +11:00
Franck Royer a335091ccf
Add `exports` keyword 2021-10-12 11:43:29 +11:00
Franck Royer b029692865
Use webpack for umd 2021-10-12 11:43:29 +11:00
Franck Royer 129b6a97d4
Release 0.13.1 2021-09-21 15:00:57 +10:00
Franck Royer 6bd114f551
Release 0.13.0 2021-09-16 14:57:10 +10:00
Franck Royer ca09c34ac6
Upgrade libp2p libraries 2021-09-03 16:02:22 +10:00
Franck Royer 3bf7e2250c
Release 0.12.0 2021-09-02 16:38:56 +10:00
Franck Royer 8ed55c43c1
Remove stub types definition 2021-08-20 14:08:52 +10:00
Franck Royer 8fce1ad884
Release 0.11.0
### Added
- Examples: New Ethereum Private Message Using Wallet Encryption
  [Web App](./examples/eth-pm-wallet-encryption/README.md)
  example that demonstrates the usage of `eth_encrypt` API (available on
  Metamask) and EIP-712 for typed structured data signing.
- New `bootstrap` option for `Waku.create` to easily connect to Waku
  nodes upon start up.
- Support for `startTime` and `endTime` in Store queries to filter by
  time window as per [21/WAKU2-FTSTORE](https://rfc.vac.dev/spec/21/).

### Changed
- Renamed `discover.getStatusFleetNodes` to
  `discovery.getBootstrapNodes`;
  Changed the API to allow retrieval of bootstrap nodes from other
  sources.
- Examples: Renamed `eth-dm` to `eth-pm`; "Direct Message" can lead to
  confusion with "Direct Connection" that
  refers to low latency network connections.
- Examples (eth-pm): Use sign typed data EIP-712 instead of personal
  sign.
- Upgraded dependencies to remove warning at installation.
- **Breaking**: Moved `DefaultPubSubTopic` to `waku.ts` and fixed the
  casing.
- **Breaking**: Rename all `pubsubTopic` occurrences to `pubSubTopic`,
  across all interfaces.

### Removed
- Examples (cli-chat): The focus of this library is Web environment;
  Several examples now cover usage of Waku Relay and Waku Store making cli-chat example obsolete;
  web-chat POC should be preferred to use the [TOY-CHAT](https://rfc.vac.dev/spec/22/) protocol.
- `ChatMessage` has been moved from js-waku to web-chat example;
  it is a type used for the [TOY-CHAT](https://rfc.vac.dev/spec/22/) protocol;
  js-waku users should not build on top if this toy protocol and instead design message data structures appropriate to their use case.
- Unused dependencies & scripts.
2021-08-20 12:15:23 +10:00
Franck Royer 057625223b
Add some relevant keywords 2021-08-20 10:54:13 +10:00
Franck Royer 11dbdf3033
Remove unused scripts 2021-08-20 10:54:12 +10:00