animate-css / animate.css

🍿 A cross-browser library of CSS animations. As easy to use as an easy thing.
https://animate.style/
Other
80.85k stars 16.24k forks source link

Make sure importing source files is possible #1331

Open eltonmesquita opened 3 years ago

eltonmesquita commented 3 years ago

We should make sure that it's possible to import individual source files directly from the node_modules so developers won't need to resort to custom builds which are very annoying to maintain and not very practical these days.

I think we should check/add support for at least:

Have a look at #1307 for more context.

warengonzaga commented 3 years ago

How about starting with webpack @eltonmesquita?

ramanjitsingh-hub commented 3 years ago

I am a newbie can you verify that this problem can be solved using this link https://webpack.js.org/guides/getting-started/ I have time to combine a pr please go through this as I definitely need guidance

joeworkman commented 3 years ago

Have a look at esbuild as well... https://esbuild.github.io

warengonzaga commented 3 years ago

Have a look at esbuild as well... https://esbuild.github.io

This is promising I need to check this out first. Thanks for sharing @joeworkman.

ramanjitsingh-hub commented 3 years ago

I can combine a pr if someone can guide me through it

eltonmesquita commented 3 years ago

This might not need a PR. The main task is to verify if it's possible today and if any change is required on our side, then putting a PR together with the fix will be the way to go.

Just a reminder that it already works when importing the main files in the root of the project, we just need to be sure that importing the source files, in the source directory, work properly in these main bundlers.

eltonmesquita commented 2 years ago

I've tried it out with webpack and css-loader and it worked just fine. It's just a bit weird to use as you have to point to the whole path for the file for it to work. Like this:

import "animate.css/source/attention_seekers/bounce.css";
import "animate.css/source/animate.css";

It's not very practical. I'm not sure if we can provide a better way to use it without using some js, which I'm open to. Maybe an index.js file exporting all the CSS files could work?

debanjanbanerjee46 commented 1 year ago

I want to work on this issue

Arif980 commented 6 months ago

I want to work