NPM module not working as expected in Meteor

Hi all,

I’m trying to use this NPM module:

It’s pretty straight forward with the usage guide.

Install with npm install --save tiny-date-picker

Then import: import TinyDatePicker from 'tiny-date-picker';

Then initialise the module: TinyDatePicker('.some-class-or-id-or-whatever');

But instead of getting what show at the demo, I get the following broken UI.

Isn’t it Meteor is 100% compatible with NPM? Why it doesn’t work as it should?

Please advice on what I did wrong. Thanks.

It suppose to look like this:

It’s a CSS issue, you didn’t include the css.

You can see that they’ve referenced the CSS file in their example here.


Thanks. Will do that now. Appreciate much.

I put the CSS file to /public folder and add the following to <head>

<link rel=“stylesheet” href="/tiny-date-picker.css">

and it’s working now. Thanks @alawi

1 Like