rollup / rollup-plugin-commonjs

This module has moved and is now available at @rollup/plugin-commonjs / https://github.com/rollup/plugins/blob/master/packages/commonjs
MIT License
501 stars 126 forks source link

Add more reserved keywords #416

Closed yesmeck closed 4 years ago

yesmeck commented 4 years ago

Add document self window global to reserved words.

shellscape commented 4 years ago

self and global are definitely not universal reserved words, but might be considered so in certain environments.

window and document while global vars in a browser environment, aren't reserved and are instead "already declared."

I don't think this PR is the right approach, but we might be open to a new feature that allows specifying additional words that should be considered reserved, after the plugin is moved to it's new home at https://github.com/rollup/plugins.