Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
nuxt-lodash
Advanced tools
Lodash auto-import module for Nuxt.
nuxt-lodash
as development dependency:npm i nuxt-lodash -D
modules
section of your nuxt.config
:export default defineNuxtConfig({
modules: ["nuxt-lodash"],
});
Use any Lodash methods in your Nuxt application, they will be auto-imported!
<script setup>
const text = useToUpper("it works!");
</script>
<template>
<div>{{ text }}</div>
</template>
Name | Default | Description |
---|---|---|
prefix | 'use' | String to prepend before each Lodash function (false to disable) |
prefixSkip | 'is' | Functions that starts with this keywords will be skipped by prefix (false to disable) |
upperAfterPrefix | true | If true it will automatically uppercase first letter after prefix (false to disable) |
exclude | [] | Array of Lodash functions to exclude from auto-imports |
alias | [] | Array of array pairs to rename specific Lodash functions (prefix is still added) |
export default defineNuxtConfig({
modules: ["nuxt-lodash"],
lodash: {
prefix: "_",
prefixSkip: ["string"],
upperAfterPrefix: false,
exclude: ["map"],
alias: [
["camelCase", "stringToCamelCase"], // => stringToCamelCase
["kebabCase", "stringToKebab"], // => stringToKebab
["isDate", "isLodashDate"], // => _isLodashDate
],
},
});
MIT License © 2021-2022 - Michal Čípa
FAQs
Lodash for Nuxt
The npm package nuxt-lodash receives a total of 18,637 weekly downloads. As such, nuxt-lodash popularity was classified as popular.
We found that nuxt-lodash 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
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.