Gathering detailed insights and metrics for yuzu-loadable
Gathering detailed insights and metrics for yuzu-loadable
Gathering detailed insights and metrics for yuzu-loadable
Gathering detailed insights and metrics for yuzu-loadable
npm install yuzu-loadable
Typescript
Module System
Min. Node Version
71.6
Supply Chain
97
Quality
75.4
Maintenance
100
Vulnerability
100
License
TypeScript (93.77%)
JavaScript (5.13%)
HTML (1.1%)
Love this project? Help keep it running — sponsor us today! 🚀
Total Downloads
4,445
Last Day
1
Last Week
4
Last Month
57
Last Year
313
MIT License
8 Stars
421 Commits
2 Forks
3 Watchers
40 Branches
4 Contributors
Updated on Oct 03, 2023
Minified
Minified + Gzipped
Latest Version
2.0.1
Package Id
yuzu-loadable@2.0.1
Unpacked Size
224.20 kB
Size
48.91 kB
File Count
20
Cumulative downloads
Total Downloads
Last Day
0%
1
Compared to previous day
Last Week
-55.6%
4
Compared to previous week
Last Month
111.1%
57
Compared to previous month
Last Year
-30.1%
313
Compared to previous year
async component initializer for yuzu
Yuzu components rely on pre-existing HTML used as baseline to enhance the user experience. But in some scenarios the HTML you need is not rendered, or you have to wait for data coming from a remote API before you can initialize a component.
This is where Yuzu Loadable comes in hand.
Yuzu Loadable lets you define an async function and use its returned data to instantiate a component and its HTML template.
npm install yuzu yuzu-loadable --save
# or
yarn add yuzu yuzu-loadable
<script>
Add the following script tags before your code
1<script src="https://unpkg.com/yuzu"></script> 2<script src="https://unpkg.com/yuzu-loadable"></script>
Yuzu Loadable will be available in the global scope under YZ.Loadable
.
To provide maximum compatibility with every development environment, packages are transpiled to ES5. When used with a bundler like Webpack or rollup the module resolution system will automatically pick either the Commonjs or ESM version based on your configuration.
If you want to import the ES2017 version of a package you can do so by setting an alias on the bundler's configuration file:
1// webpack.config.js 2 3module.exports = { 4 // ... 5+ resolve: { 6+ alias: { 7+ 'yuzu-loadable': 'yuzu-loadable/dist/index.next.js' 8+ } 9+ } 10}
1// rollup.config.js 2+ import path from 'path'; 3+ import alias from 'rollup-plugin-alias'; 4 5export default { 6 input: './src/index.js', 7 plugins: [ 8 // ... 9+ alias({ 10+ 'yuzu-loadable': path.resolve(__dirname, 'node_modules/yuzu-loadable/dist/index.next.js') 11+ }) 12 ], 13};
Yuzu works in all modern browsers. In order to make it work in browsers that don't support ES2015+ features (like IE11) you need to include the yuzu-polyfills
package before any other yuzu*
package.
If you're using a package bundler add this line at the very top of your entry point:
1import 'yuzu-polyfills';
Learn more about Yuzu Loadable! Read the full documentation or browse the API.
yarn install
test
folder.yarn build
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
project is archived
Details
Reason
Found 0/27 approved changesets -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
117 existing vulnerabilities detected
Details
Score
Last Scanned on 2025-02-10
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More