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

@types/speakingurl

Package Overview
Dependencies
Maintainers
1
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/speakingurl

TypeScript definitions for speakingurl

  • 13.0.2
  • ts2.0
  • ts2.1
  • ts2.2
  • ts2.3
  • ts2.4
  • ts2.5
  • ts2.6
  • ts2.7
  • ts2.8
  • ts2.9
  • ts3.0
  • ts3.1
  • ts3.2
  • ts3.3
  • ts3.4
  • ts3.5
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
122K
decreased by-7.38%
Maintainers
1
Weekly downloads
 
Created

What is @types/speakingurl?

@types/speakingurl is a TypeScript type definition package for the 'speakingurl' library, which is used to generate slugs from strings. Slugs are URL-friendly strings typically used in web development for creating readable and SEO-friendly URLs.

What are @types/speakingurl's main functionalities?

Basic Slug Generation

This feature allows you to generate a basic slug from a given string. The generated slug is URL-friendly and typically used in web development for creating readable URLs.

const speakingurl = require('speakingurl');
const slug = speakingurl('Hello World!');
console.log(slug); // Output: 'hello-world'

Custom Separator

This feature allows you to customize the separator used in the generated slug. By default, the separator is a hyphen ('-'), but you can change it to any character you prefer.

const speakingurl = require('speakingurl');
const slug = speakingurl('Hello World!', { separator: '_' });
console.log(slug); // Output: 'hello_world'

Transliteration

This feature supports transliteration, which converts non-Latin characters to their Latin equivalents. This is useful for generating slugs from strings in various languages.

const speakingurl = require('speakingurl');
const slug = speakingurl('你好世界');
console.log(slug); // Output: 'ni-hao-shi-jie'

Custom Replacements

This feature allows you to define custom replacements for specific words or characters in the input string. This can be useful for handling special cases or ensuring consistency in the generated slugs.

const speakingurl = require('speakingurl');
const slug = speakingurl('Hello World!', { custom: { 'Hello': 'Hi' } });
console.log(slug); // Output: 'hi-world'

Other packages similar to @types/speakingurl

FAQs

Package last updated on 21 Aug 2017

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