Skip to content

Commit

Permalink
Update browser/error.ts
Browse files Browse the repository at this point in the history
Co-authored-by: Craig Morten <cmorten@users.noreply.github.com>
  • Loading branch information
lukastaegert and cmorten committed Jan 28, 2021
1 parent 26ced57 commit 4770ed5
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions browser/error.ts
@@ -1,8 +1,9 @@
import { error } from '../src/utils/error';

export const throwNoFileSystem = (method: string) => (..._args: any[]): never => {
throw Object.assign(
new Error(
`Cannot access the file system (via "${method}") when using the browser build of Rollup. Make sure you supply a plugin with custom resolveId and load hooks to Rollup.`
),
{ code: 'NO_FS_IN_BROWSER', url: 'https://rollupjs.org/guide/en/#a-simple-example' }
);
error({
code: 'NO_FS_IN_BROWSER',
message: `Cannot access the file system (via "${method}") when using the browser build of Rollup. Make sure you supply a plugin with custom resolveId and load hooks to Rollup.`,
url: 'https://rollupjs.org/guide/en/#a-simple-example'
});
};

0 comments on commit 4770ed5

Please sign in to comment.