
Security News
vlt Launches "reproduce": A New Tool Challenging the Limits of Package Provenance
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
@vue/language-core
Advanced tools
The @vue/language-core package is designed to provide core functionalities for handling Vue.js component files (.vue files) in development tools. It offers APIs for parsing, analyzing, and manipulating Vue component code, making it easier for developers to create or enhance development tools such as IDEs, linters, and compilers that work with Vue.js projects.
Parsing Vue Files
This feature allows the parsing of Vue component files, breaking down the structure into an understandable format for further processing. The code sample demonstrates how to parse a simple Vue file to access its descriptor.
import { parse } from '@vue/language-core';
const { descriptor } = parse('<template><div>Hello World</div></template>');
Analyzing Script Setup
Analyzes the script setup block of a Vue component, providing insights such as defined props. The code sample shows how to analyze a script setup block after parsing a Vue file.
import { parse, analyzeScriptSetup } from '@vue/language-core';
const { descriptor } = parse('<script setup>defineProps()</script>');
const analysis = analyzeScriptSetup(descriptor);
Transforming Vue Components
Enables the transformation of Vue component code based on specified options, which can be used for code optimization or to apply custom modifications. The code sample illustrates transforming a parsed Vue component.
import { parse, transform } from '@vue/language-core';
const { descriptor } = parse('<template><div>{{ msg }}</div></template>');
const transformed = transform(descriptor, { /* transformation options */ });
A parser that converts Vue component files into an AST format that ESLint can understand, enabling linting of Vue files. While it focuses on linting, @vue/language-core offers a broader range of functionalities for analyzing and transforming Vue components.
A webpack loader that automatically imports Vuetify components used in a project. It's more specific to Vuetify and webpack, whereas @vue/language-core provides core functionalities applicable to various development tools and environments.
2.2.4 <sup>official</sup>, 2.2.5 <sup>insiders</sup> (2025-02-22)
$attrs
, $el
, $refs
and $slots
(#5135) - Thanks to @KazariEX!generateSfcBlockSection
to the end to fix missing comma errors (#5184) - Thanks to @zhiyuanzmj!TS4081
(#5192) - Thanks to @KazariEX!@vue-generic
to improve offset calculation (#5193) - Thanks to @Gehbt!undefined
for model with default value (#5198) - Thanks to @RylanBueckert-Broadsign!v-scope
implemention - Thanks to @KazariEX!v-for
- Thanks to @KazariEX!declaration
to track more errors - Thanks to @KazariEX!@vue-expect-error
support (#5176) - Thanks to @machty!FAQs
Unknown package
The npm package @vue/language-core receives a total of 2,474,805 weekly downloads. As such, @vue/language-core popularity was classified as popular.
We found that @vue/language-core demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 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
vlt's new "reproduce" tool verifies npm packages against their source code, outperforming traditional provenance adoption in the JavaScript ecosystem.
Research
Security News
Socket researchers uncovered a malicious PyPI package exploiting Deezer’s API to enable coordinated music piracy through API abuse and C2 server control.
Research
The Socket Research Team discovered a malicious npm package, '@ton-wallet/create', stealing cryptocurrency wallet keys from developers and users in the TON ecosystem.