
Security News
TypeScript is Porting Its Compiler to Go for 10x Faster Builds
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
upper-case-first
Advanced tools
The upper-case-first npm package is a simple utility that allows you to capitalize the first letter of a string. It is useful when you need to ensure that a string is properly capitalized, such as when formatting names or titles.
Capitalize the first letter of a string
This feature takes a string and capitalizes the first character of that string. It is useful for formatting text that needs to start with a capital letter.
"use strict";
var upperCaseFirst = require('upper-case-first');
console.log(upperCaseFirst('string')); // 'String'
The 'capitalize' package provides a similar functionality to upper-case-first, allowing users to capitalize the first letter of a string or every word in a string. It offers more options than upper-case-first, such as capitalizing every word or handling edge cases differently.
The 'titleize' package is another alternative that converts a string into a title case, where the first letter of each major word is capitalized. It is more comprehensive than upper-case-first as it deals with a full string and applies title case rules, not just capitalizing the first letter.
The 'to-capital-case' package converts a string to a capital case where the first letter of each word is capitalized. This package is more similar to 'titleize' and is different from upper-case-first which only capitalizes the first letter of the entire string.
Transforms the string with the first character in upper cased.
npm install upper-case-first --save
import { upperCaseFirst } from "upper-case-first";
upperCaseFirst("test"); //=> "Test"
MIT
FAQs
Transforms the string with the first character in upper cased
The npm package upper-case-first receives a total of 5,730,866 weekly downloads. As such, upper-case-first popularity was classified as popular.
We found that upper-case-first demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
TypeScript is porting its compiler to Go, delivering 10x faster builds, lower memory usage, and improved editor performance for a smoother developer experience.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.