rollup/rollup-plugin-node-resolve

Entry field from package.json order of preference isn't clear

caccialdo opened this issue · 2 comments

From looking at the options documentation, it is not clear in which order fields inside package.json will be chosen.

IMO organising the options like this would help make the distinction clearer:

{
  main: true,
  jsnext: true,
  browser: true
}
// vs.
{
  entryFields: ['main', 'jsnext:main', 'browser'] // Default to ['main']
}

This PR #182 should fix it

I think it can be closed now. Currently, we have mainFields.