rust/editors/code/rollup.config.js

28 lines
788 B
JavaScript
Raw Normal View History

// @ts-check
2019-12-30 09:51:44 +01:00
import resolve from '@rollup/plugin-node-resolve';
import commonjs from '@rollup/plugin-commonjs';
import nodeBuiltins from 'builtin-modules';
/** @type { import('rollup').RollupOptions } */
2019-12-30 09:51:44 +01:00
export default {
2020-05-20 20:03:49 +02:00
input: 'out/src/main.js',
2019-12-30 09:51:44 +01:00
plugins: [
resolve({
preferBuiltins: true
}),
commonjs({
namedExports: {
// squelch missing import warnings
2020-01-15 11:47:56 +01:00
'vscode-languageclient': ['CreateFile', 'RenameFile', 'ErrorCodes', 'WorkDoneProgress', 'WorkDoneProgressBegin', 'WorkDoneProgressReport', 'WorkDoneProgressEnd']
2019-12-30 09:51:44 +01:00
}
})
],
external: [...nodeBuiltins, 'vscode'],
output: {
2020-05-20 20:03:49 +02:00
file: './out/src/main.js',
2020-02-15 22:04:51 +01:00
format: 'cjs',
exports: 'named'
2019-12-30 09:51:44 +01:00
}
};