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

fix(run): prepare for Rollup 3 #1285

Merged
merged 1 commit into from
Oct 10, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 4 additions & 0 deletions packages/run/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@

Using this plugin gives much faster results compared to what you would do with [nodemon](https://nodemon.io/).

## Requirements

This plugin requires an [LTS](https://github.com/nodejs/Release) Node version (v14.0.0+) and Rollup v2.0.0+.

## Install

Using npm:
Expand Down
37 changes: 23 additions & 14 deletions packages/run/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,15 @@
"author": "Rich Harris",
"homepage": "https://github.com/rollup/plugins/tree/master/packages/run/#readme",
"bugs": "https://github.com/rollup/plugins/issues",
"main": "dist/index.js",
"module": "dist/index.es.js",
"main": "./dist/cjs/index.js",
"module": "./dist/es/index.js",
"exports": {
"types": "./types/index.d.ts",
"import": "./dist/es/index.js",
"default": "./dist/cjs/index.js"
},
"engines": {
"node": ">=8.0.0"
"node": ">=14.0.0"
},
"scripts": {
"build": "rollup -c",
Expand All @@ -33,6 +38,7 @@
},
"files": [
"dist",
"!dist/**/*.map",
"types",
"README.md",
"LICENSE"
Expand All @@ -43,23 +49,26 @@
"run"
],
"peerDependencies": {
"rollup": "^2.0.0"
"rollup": "^2.0.0||^3.0.0"
},
"peerDependenciesMeta": {
"rollup": {
"optional": true
}
},
"dependencies": {
"@types/node": "14.0.26"
"@types/node": "14.18.30"
},
"devDependencies": {
"@rollup/plugin-typescript": "^5.0.2",
"del": "^5.1.0",
"rollup": "^2.67.3",
"sinon": "9.0.2",
"typescript": "^4.1.2"
"@rollup/plugin-typescript": "^8.5.0",
"del": "^6.1.1",
"rollup": "^3.0.0-7",
"sinon": "^14.0.0",
"typescript": "^4.8.3"
},
"types": "types/index.d.ts",
"types": "./types/index.d.ts",
"ava": {
"babel": {
"compileEnhancements": false
},
"workerThreads": false,
"files": [
"!**/fixtures/**",
"!**/output/**",
Expand Down
13 changes: 0 additions & 13 deletions packages/run/rollup.config.js

This file was deleted.

7 changes: 7 additions & 0 deletions packages/run/rollup.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { readFileSync } from 'fs';

import { createConfig } from '../../shared/rollup.config.mjs';

export default createConfig({
pkg: JSON.parse(readFileSync(new URL('./package.json', import.meta.url), 'utf8'))
});
2 changes: 1 addition & 1 deletion packages/run/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { resolve, join, dirname } from 'path';

import { Plugin, RenderedChunk } from 'rollup';

import { RollupRunOptions } from '../types';
import type { RollupRunOptions } from '../types';

export default function run(opts: RollupRunOptions = {}): Plugin {
let input: string;
Expand Down
66 changes: 29 additions & 37 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.