Export functions on the utils module
See original GitHub issueHello 👋
I’m building a datepicker on top of this library and wanted to know if it’s possible to export the functions on the utils
module. In my use case, I have a Today button and to make it work properly, I’m making use of the normalizeDate and isEqual functions (but copying them).
Would be nice to import them directly from dayzed. What do you think about it?
Thanks in advance.
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (7 by maintainers)
Top Results From Across the Web
Simplify exporting and importing of your JavaScript utility ...
I do this by creating a src/utils/index.js file: const { startOfDay } = require('./dates')module.exports = function useUtils() { return { startOfDay } }....
Read more >module.exports – How to Export in Node.js and JavaScript
In this article, I will show you how to share functions and values by exporting and importing modules in Node.js.
Read more >Understanding module.exports and exports in Node.js
Here we're assigning the functions and values we want to export to an exports property on module — and of course, this works...
Read more >Node.js Export Module - TutorialsTeacher
Learn how to export different types as a Node.js modules here. ... The following example exposes an object with the log function as...
Read more >Util::Any - to export any utilities and to create your own utility ...
If your utility module which inherited Util::Any has utility functions and export them by Exporter-like module, behaviour of 'all' and '-all' or ':all'...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@arthurdenner
date-fns
should be added to thedependencies
since the methods that will be used from it will be packaged in with the<Dayzed>
component dist bundle.@arthurdenner I think this is ready for you now. I added some integration tests around the lib using Cypress.io - https://github.com/deseretdigital/dayzed/pull/16. Let me know if you have any questions. Thanks!