
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
@aw-studio/vue-lit-image-next
Advanced tools
This version of the vue-lit-image was specifically written to support Vue 3 applications. If you're running Vue 2 you should check out https://github.com/aw-studio/vue-lit-image.
For normal websites built with blade in Laravel we already have the <x-lit-image />
as a component to handle all the annoying tasks for images like lazyloading but what if you have the same imageobjects in a vue application and want to use the same magic there? The vue-lit-image has you covered, it also takes the media object in the image property and does all the lazyloading, dynamic image sizing and it even sets the alt and title attributes for you.
npm install @aw-studio/vue-lit-image-next
In your app.js require the package and use the component. When using the component you have to specify the conversions according to your settings in the lit.php config file:
import { createApp } from 'vue';
import Test from './components/Test.vue';
import LitImage from '@aw-studio/vue-lit-image-next';
const app = createApp({
components: {
Test,
},
});
app.use(LitImage, {
conversions: {
sm: 300,
md: 500,
lg: 900,
xl: 1400,
},
});
app.mount('#app');
Inside your Vue files when you want to use the vue-lit-image, you want to give the prop image
the media object just like the blade component would:
<lit-image :image="image" />
You can also style it using the classes
prop:
<lit-image :image="image" classes="w-full" />
FAQs
A vue-lit-image that supports vue 3.
The npm package @aw-studio/vue-lit-image-next receives a total of 1 weekly downloads. As such, @aw-studio/vue-lit-image-next popularity was classified as not popular.
We found that @aw-studio/vue-lit-image-next demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers 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
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.