import-js/eslint-plugin-import

Check for importing named exports from CJS module

Open

#928 建立於 2017年9月15日

在 GitHub 查看
 (8 留言) (2 反應) (0 負責人)JavaScript (4,946 star) (1,540 fork)batch import
enhancementhelp wanted

描述

With the new node.js 8.5 ESM support importing CJS modules as if they had named exports is not supported. (Unlike Babel)

Eg:

// bad
import { get } from 'lodash';

//good
import _ from 'lodash';
const get = _.get;

//good
import { get } from 'lodash-es';

貢獻者指南