I would like to import specific properties from lodash and export them under the same object.
Right now I am doing
import { omit, get, set } from 'lodash';
const _ = {
omit,
get,
set
};
export default _;
As you can see, I need to repeat each and every property twice.
Is there some syntax that allows me to do it once? for example something like:
import {
omit,
get,
set } as _ from 'lodash';
export default _;
would be great! but this is obviously not supported at the moment.
Is there any other syntax that allows this?
export { omit, get, set } from 'lodash';?import * as _ from ..any way around it?