
Security News
TypeScript is Porting Its Compiler to Go for 10x Faster Builds
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
vue-parallaxy
Advanced tools
Is a compontent for fast 60fps parallax scroll effects in vue 2.
npm install vue-parallaxy
or yarn add vue-parallaxy
vue-parallax works with slots. So you can pass an image or even srcsets for better mobile experiences.
// Image.vue
<template>
<parallax>
<img src="path/cool-background-image.jpg" alt="very cool bg">
</parallax>
</template>
<script>
import Parallax from 'vue-parallaxy'
export default {
components: {
Parallax
}
}
</script>
Prop | Type | Default Value | Description |
---|---|---|---|
parallax | Boolean | true | Activates parallax effect |
speedFactor | Number | 0.15 | factor on how strong the effect is |
fixed | Boolean | false | Other parallax effect. Image is fixed in position |
sectionHeight | Number | 70 | section height for mobile |
breakpoint | String | '(min-width: 968px)' | Media query for mobile deactivation |
sectionClass | String | 'Masthead' | CSS class of the outer section tag |
containerClass | String | 'Masthead__image' | CSS class of the container holding the image |
parallaxClass | String | 'is-parallax' | Modifier class for the parallax effect |
fixedClass | String | 'is-fixed' | Modifier class for the fixed parallax effect |
You can change some of the behavior by changing the css classes. To be more clean, you can change them over the props. No need to overwrite or !important
the existing classes.
# install dependencies
npm install
# serve with hot reload at localhost:8080
npm run dev
# build for production with minification
npm run build
# run unit tests
npm run unit
# run all tests
npm test
For detailed explanation on how things work, checkout the guide and docs for vue-loader.
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)This software is distributed under MIT license.
FAQs
Vue 2 component for parallax scrolling effects
The npm package vue-parallaxy receives a total of 425 weekly downloads. As such, vue-parallaxy popularity was classified as not popular.
We found that vue-parallaxy demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.