Skip to content

Instantly share code, notes, and snippets.

@mohnish
Forked from tj/modules.js
Created April 9, 2017 19:32
Show Gist options
  • Save mohnish/e23eaba82ecae4fa2a93564b3463245c to your computer and use it in GitHub Desktop.
Save mohnish/e23eaba82ecae4fa2a93564b3463245c to your computer and use it in GitHub Desktop.
import React from 'react' // export default React
import React, Component from 'react' // first is default, followed by exported
import foo from 'lib' // no default, so just grab all exports
// Maybe there's some reasoning behind the other choices regarding static analysis but
// most of the otheres seem unnecessary. Alternatively just using the destructuring syntax
// would be pretty nice and easier to remember.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment