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

Can't update breakpoints #30

Open
johannes-z opened this issue Jan 8, 2019 · 3 comments
Open

Can't update breakpoints #30

johannes-z opened this issue Jan 8, 2019 · 3 comments

Comments

@johannes-z
Copy link

I have an application where the user can specify breakpoints to render different data. I cannot change the breakpoint at runtime however. Calling Vue.use(VueMq, { ... }) when it's already set doesn't do anything.

Something along the lines of this would be great:

Vue.use(VueMq, {
  breakpoints: { // default breakpoints - customize this
    sm: 450,
    md: 1250,
    lg: Infinity,
  }
  defaultBreakpoint: 'sm' // customize this for SSR
})

// in component
this.$mq.update('sm', 550)
@AlexandreBonaventure
Copy link
Owner

Hey @johannes-z, that is a good idea! Intending to implement

@zerdmann
Copy link

The ability to update the default here would be nice too.

@zeratul1
Copy link

Please check this PR #37

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

No branches or pull requests

4 participants