Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support root #1

Open
existentialism opened this issue Nov 21, 2016 · 1 comment
Open

Support root #1

existentialism opened this issue Nov 21, 2016 · 1 comment
Assignees

Comments

@existentialism
Copy link
Member

existentialism commented Nov 21, 2016

Transform:

import dt from 'date-fns';

const x = dt.addHours(new Date(), 1); 
const y = dt.format(y, 'MM/DD/YYYY');

to

import addHours from 'date-fns/add_hours';
import format from 'date-fns/format';

const x = addHours(new Date(), 1); 
const y = format(y, 'MM/DD/YYYY')
@existentialism existentialism self-assigned this Dec 6, 2016
@lukewlms
Copy link

This would be very useful for us too! We've been using and recommending date-fns a lot. Simplifying imports would mean our overhead to use date-fns in new files/new capabilities in existing files goes way down.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants