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

Q: Anyway to install with all plugins? #1364

Open
naseemkullah opened this issue Jan 29, 2021 · 3 comments
Open

Q: Anyway to install with all plugins? #1364

naseemkullah opened this issue Jan 29, 2021 · 3 comments
Labels
enhancement New feature or request

Comments

@naseemkullah
Copy link

The modularity is great, but is there a way to install the "full" version?

@iamkun
Copy link
Owner

iamkun commented Jan 29, 2021

No at present, but it's nice to have one, do we?

@lachlansleight
Copy link

lachlansleight commented Jan 29, 2021

I'm not certain, but couldn't you just make a file like `dayjsfull.js':

import dayjs from 'dayjs';
import moduleA from 'dayjs/module/moduleA';
import moduleB from 'dayjs/module/moduleB';
dayjs.extend(moduleA);
dayjs.extend(moduleB);

export default dayjs;

and then just go import dayjs from './dayjsfull' to get a dayjs object that's extended with whatever plugins you want to use across your scripts?

@iamkun
Copy link
Owner

iamkun commented Jan 29, 2021

looks sweet

@iamkun iamkun added the enhancement New feature or request label Jan 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants