title: ParcelJS build is not honoring fractional module
body: <p>I'm building a mock app in HTML, CSS and JS. However, after running the 'npm run build' to compress, build and bundle the files in dist folder and uploading to netlify server to test the build version, it is throwing
  &quot;Uncaught ReferenceError: assignment to undeclared variable Fraction&quot;</p>
  <p>I've installed fractional module via 'npm i fractional' and the development version of the app runs just fine.
  The version of Parcel used for bundling the app is 2.0.0-rc.0</p>
  <p>I've tried creating an extra file called index.d.ts wherein I'm declaring the module as suggested by JS
  i.e. declare module 'fractional' and tried to run the app on netlify using this build version as well, but no luck.</p>
  <p>The fractional module is using is used in one of .js file for calculating the quantity of an ingredient to be used in a specific recipe and the way the module is imported into the JS file is by import command i.e.
  import { Fraction } from 'fractional'.</p>
  <p>Code snippet from recipeView.js where Fractional module is used.</p>
  <pre><code>
      import { Fraction } from 'fractional';
      
      export class RecipeView extends View {
        // Method to generate ingredients list
        _ingredientsList(ing) {
          return `
              &lt;li class=&quot;recipe__ingredient&quot;&gt;
                  &lt;svg class=&quot;recipe__icon&quot;&gt;
                  &lt;use href=&quot;${icon}#icon-check&quot;&gt;&lt;/use&gt;
                  &lt;/svg&gt;
                  &lt;div class=&quot;recipe__quantity&quot;&gt;${
                    ing.quantity ? new Fraction(ing.quantity).toString() : ''
                  }&lt;/div&gt;
                  &lt;div class=&quot;recipe__description&quot;&gt;
                  &lt;span class=&quot;recipe__unit&quot;&gt;${ing.unit}&lt;/span&gt;
                  ${ing.description}
                  &lt;/div&gt;
              &lt;/li&gt;
          `;
        }
      }
  </code></pre>
  <p>The above protected method is used in the same class to generate a markup.
  <code>_generateMarkup() { return</code>
  Recipe ingredients
  
  ${this._data.ingredients
  .map(ing =&gt; this._ingredientsList(ing))
  .join('')}
  
  
  `</p>
  <pre><code>`
  </code></pre>
  <p>Below is the code snippet from package.json file
  `</p>
  <pre><code>&quot;scripts&quot;: {
      &quot;dev&quot;: &quot;parcel index.html&quot;,
      &quot;build&quot;: &quot;parcel build index.html --dist-dir ./dist&quot;
    },
    &quot;author&quot;: &quot;ABC&quot;,
    &quot;license&quot;: &quot;ISC&quot;,
    &quot;devDependencies&quot;: {
      &quot;@parcel/transformer-image&quot;: &quot;^2.0.0-rc.0&quot;,
      &quot;@parcel/transformer-sass&quot;: &quot;^2.0.0-rc.0&quot;,
      &quot;@types/regenerator-runtime&quot;: &quot;^0.13.1&quot;,
      &quot;parcel&quot;: &quot;^2.0.0-rc.0&quot;
    },
    &quot;dependencies&quot;: {
      &quot;fractional&quot;: &quot;^1.0.0&quot;
    }
  </code></pre>
  <p>`</p>
  <p>Any help/suggestion/advice is appreciated here.</p>