Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/shazron/node-18-tests
Various node-18 tests
https://github.com/shazron/node-18-tests
Last synced: 8 days ago
JSON representation
Various node-18 tests
- Host: GitHub
- URL: https://github.com/shazron/node-18-tests
- Owner: shazron
- Created: 2022-12-30T04:17:40.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2022-12-30T04:41:07.000Z (almost 2 years ago)
- Last Synced: 2024-10-30T02:42:44.304Z (about 2 months ago)
- Language: JavaScript
- Size: 2.93 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# node-18-tests
- Various node-18 tests.
- Tests that `node:` protocol imports are **not** required in node-18.
- Test that the global fetch is not the same as node-fetch (in case node-fetch just defaults to the global fetch). This is for compatibility reasons since node-fetch is not 100% compliant with the spec.
- Includes a linter rule to detect if you are using the `node:` protocol import.## Pre-requisites
1. Use [nvm](https://github.com/nvm-sh/nvm) to auto-switch to node-18 when in this repo (via the `.nvmrc`)
2. npm install## Usage
- Run `npm test`
- There should be one warning regarding the `require` that does not use a `node:` protocol import
- All tests should pass under node 18## Eslint
Use the `.eslintrc.json` configuration in your own repos to detect whether you are using `node:` protocol imports.