Socket
Socket
Sign inDemoInstall

@vue/runtime-core

Package Overview
Dependencies
2
Maintainers
2
Versions
202
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @vue/runtime-core

@vue/runtime-core


Version published
Weekly downloads
2.9M
increased by3.49%
Maintainers
2
Install size
1.03 MB
Created
Weekly downloads
 

Package description

What is @vue/runtime-core?

The @vue/runtime-core package is a part of the Vue.js framework that provides the core runtime components necessary for Vue applications to function. It includes the logic for the virtual DOM, components, reactivity system, and other essential features that enable developers to build interactive user interfaces.

What are @vue/runtime-core's main functionalities?

Reactivity System

The reactivity system allows developers to create reactive state objects that automatically update the DOM when the state changes.

{"import { reactive } from '@vue/runtime-core';\nconst state = reactive({ count: 0 });"}

Component Creation

This feature enables developers to define Vue components using the Composition API, which is a function-based approach to creating and managing component state and behavior.

{"import { defineComponent } from '@vue/runtime-core';\nconst MyComponent = defineComponent({\n  setup() {\n    // Component logic here\n  }\n});"}

Custom Renderer API

The Custom Renderer API allows developers to create custom renderers for Vue, enabling the use of Vue's reactivity and component system with different rendering backends, such as canvas or WebGL.

{"import { createRenderer } from '@vue/runtime-core';\nconst { render } = createRenderer({\n  patchProp,\n  ...otherOptions\n});"}

Other packages similar to @vue/runtime-core

Changelog

Source

3.4.25 (2024-04-24)

Bug Fixes

Readme

Source

@vue/runtime-core

This package is published only for typing and building custom renderers. It is NOT meant to be used in applications.

For full exposed APIs, see src/index.ts.

Building a Custom Renderer

import { createRenderer } from '@vue/runtime-core'

const { render, createApp } = createRenderer({
  patchProp,
  insert,
  remove,
  createElement
  // ...
})

// `render` is the low-level API
// `createApp` returns an app instance with configurable context shared
// by the entire app tree.
export { render, createApp }

export * from '@vue/runtime-core'

See @vue/runtime-dom for how a DOM-targeting renderer is implemented.

Keywords

FAQs

Last updated on 24 Apr 2024

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc