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

MixItUp Pagination not working with Vite JS #615

Open
Toms15 opened this issue Sep 13, 2023 · 0 comments
Open

MixItUp Pagination not working with Vite JS #615

Toms15 opened this issue Sep 13, 2023 · 0 comments

Comments

@Toms15
Copy link

Toms15 commented Sep 13, 2023

I have a modular JavaScript project with Laravel and Vite JS.
I installed MixItUp via npm.
Following the instructions on your site I added MixItUp Pagination:

import mixitup from 'mixitup'; // loaded from node_modules
import mixitupPagination from '../path/to/mixitup-pagination'; // loaded from a directory of your choice within your project
// Call the mixitup factory's .use() method, passing in the extension to install it
mixitup.use(mixitupPagination);

I get this error in the console:
The requested module '/resources/js/modules/mixitup-pagination.js' does not provide an export named 'default'

If I change the import like this:
import * as mixitupPagination from './mixitup-pagination'

I get this error in the console:
Uncaught Error: [MixItUp Pagination] MixItUp core not found

How can I fix this and import MixItUp Pagination correctly?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant