Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

vue3-lottie

Package Overview
Dependencies
Maintainers
1
Versions
62
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

vue3-lottie

A simple but complete library template for Vue 3 + TypeScript

  • 0.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
47K
decreased by-12.84%
Maintainers
1
Weekly downloads
 
Created
Source

Vue 3 + TypeScript Library Template

A simple but complete library template for Vue 3 + TypeScript

Getting started

Getting the code by git clone or click Use this template right above.

Then use yarn or other package manager to install dependencies.

CSS

This template includes Scss with it. Scoped style in Vue SFC is also supported. All the styles will be build into a index.css right in the project root.

When using your library by npm package in another project, you can import this css by

import '{YOUR_LIB_NAME}/index.css'

Dev server

The dev server is provided by Vite. To start the dev server, run

yarn dev

Writing packages

Simply creating a folder in packages and add it to packages/index.ts, and it's done.

Build your packages

yarn build

Will build your packages in two format ( esm and CommonJS ) using rollup instead of Vite due to the issue when generating .d.ts file.

Once everything done, you can pack your library by npm pack or publish it by npm publish

External dependencies

If you want to exclude your dependencies from your build result:

  1. Add the package to peerDependencies in package.json
  2. Add the package to external in rollup.config.js

When using this library, remember to install these peerDependencies.

About d.ts

TypeScript declaration files will generated into lib folder once you build this template. That means the decalration files will be published in the npm package.

Also, .vue.d.ts will be generated for Vue SFC.

FAQs

Package last updated on 16 Jan 2022

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc