Socket
Socket
Sign inDemoInstall

svg-text-path

Package Overview
Dependencies
4
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    svg-text-path

Convert to Path Textfields within an SVG file


Version published
Maintainers
1
Created

Readme

Source

Convert to Path Textfields in SVG file

npm install --save svg-text-path
  • Example usage
const svgToPath = require('svg-text-path');
  • Load and save paths of the svg file
var options={
source:'./public/convert/svg.svg',
destination:'./public/convert/svg-convert.svg'
}
  • Generates convert to path svg and saves to destination path
const convertFile=await svgToPath.conversion(options);

Add Fonts

  • Open svg-text-path/config/fonts.json file
{'font': [{
'Times New Roman': {
'dest': './public/fonts/times.ttf'
}
}]}
  • Simply add more fonts to json
'My New Font Name': {
'dest': 'My New Font Path'
}
{'font': [{
'Times New Roman': {
'dest': './public/fonts/times.ttf'
},
'My New Font Name': {
'dest': 'My New Font Path'
}
}]}

Keywords

FAQs

Last updated on 03 Jan 2022

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