Wikiki / bulma-carousel

Display a carousel
MIT License
136 stars 99 forks source link

Carousel Navigation (or maybe the carousel module) does not work under Vuejs #52

Open Scarittagle opened 6 years ago

Scarittagle commented 6 years ago

I installed thru npm.

and I imported the module under App.vue Not sure is the way I imported it having problem or something else, if I import it like this:

<style lang="sass"> @import '~bulma' @import '~bulma-carousel'

the npm will throw an Module build failed error: Invalid CSS after "!": expected 1 selector or at-rule, was '!function(e,t){"obj' in F:\axd-tech-web-portal\node_modules\bulma-carousel\dist\js\bulma-carousel.min.js (line 1, column 1)

if I only import the sass: <style lang="sass"> @import '~bulma' @import '~bulma-carousel/dist/css/bulma-carousel'

it renders just fine but it lost the functionality of navigation, animation, etc that requires JS.

Wikiki commented 6 years ago

The last import try is the good one. But don't forget to also include the js file into your project to get the carousel works.

Scarittagle commented 6 years ago

How to include it? I'm using the webpack so it's modularized.

motia commented 5 years ago

@Scarittagle , you can check how I did it here. Or you can use the package directly if you feel so.