Security News
PyPI’s New Archival Feature Closes a Major Security Gap
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
@cloudfour/lite-model-viewer
Advanced tools
Lite Model-Viewer is a web component to lazy-load <model-viewer>
for improved performance.
The <lite-model-viewer>
web component accepts all the same attributes as <model-viewer>
, and will display a poster image if provided. When <lite-model-viewer>
is clicked, it will inject the <model-viewer>
element into the page, which will immediately activate and load the 3D file.
npm install @cloudfour/lite-model-viewer
<lite-model-viewer
src="your-asset.glb"
poster="your-poster.webp"
ar
camera-controls
shadow-intensity="1"
>
<button>View Model</button>
</lite-model-viewer>
<script type="module" src="lite-model-viewer.js"></script>
Note that although we're adding a <button>
element, it's just a visual indicator. There is a click event listener applied to the entire <lite-model-viewer>
element, so the user can click anywhere on the poster image to trigger the load event.
<lite-model-viewer>
will be applied to <model-viewer>
.
<model-viewer>
docs for more info on available attributes.<template>
element to pass content into <model-viewer>
, to set a custom progress bar, etc.height
and width
attribute, which will apply to both the <lite-model-viewer>
preview and the lazy-loaded <model-viewer>
element.id="model-viewer-script"
attribute. If Lite Model-Viewer detects this script, it will not load the script from Google's CDN.FAQs
A lazy-loaded model-viewer web component
The npm package @cloudfour/lite-model-viewer receives a total of 34 weekly downloads. As such, @cloudfour/lite-model-viewer popularity was classified as not popular.
We found that @cloudfour/lite-model-viewer demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 6 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
PyPI now allows maintainers to archive projects, improving security and helping users make informed decisions about their dependencies.
Research
Security News
Malicious npm package postcss-optimizer delivers BeaverTail malware, targeting developer systems; similarities to past campaigns suggest a North Korean connection.
Security News
CISA's KEV data is now on GitHub, offering easier access, API integration, commit history tracking, and automated updates for security teams and researchers.