@stryke/string-format 0.9.0 → 0.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/acronyms.cjs +12 -2
- package/dist/acronyms.mjs +1 -1
- package/dist/title-case.cjs +17 -14
- package/dist/title-case.d.ts +5 -3
- package/dist/title-case.mjs +1 -1
- package/package.json +3 -3
package/dist/acronyms.cjs
CHANGED
|
@@ -156,6 +156,9 @@ const ACRONYMS = exports.ACRONYMS = {
|
|
|
156
156
|
CTA: {
|
|
157
157
|
description: "Call To Action"
|
|
158
158
|
},
|
|
159
|
+
CWD: {
|
|
160
|
+
description: "Current Working Directory"
|
|
161
|
+
},
|
|
159
162
|
CX: {
|
|
160
163
|
description: "Customer Experience"
|
|
161
164
|
},
|
|
@@ -177,8 +180,12 @@ const ACRONYMS = exports.ACRONYMS = {
|
|
|
177
180
|
display: "DevOps"
|
|
178
181
|
},
|
|
179
182
|
DEVENV: {
|
|
180
|
-
description: "
|
|
181
|
-
display: "
|
|
183
|
+
description: "Devenv",
|
|
184
|
+
display: "Devenv"
|
|
185
|
+
},
|
|
186
|
+
DOTENV: {
|
|
187
|
+
description: "Dotenv (.env)",
|
|
188
|
+
display: "Dotenv"
|
|
182
189
|
},
|
|
183
190
|
DIRENV: {
|
|
184
191
|
description: "DirEnv",
|
|
@@ -293,6 +300,9 @@ const ACRONYMS = exports.ACRONYMS = {
|
|
|
293
300
|
description: "Function as a Service",
|
|
294
301
|
display: "FaaS"
|
|
295
302
|
},
|
|
303
|
+
GC: {
|
|
304
|
+
description: "Garbage Collection"
|
|
305
|
+
},
|
|
296
306
|
GCP: {
|
|
297
307
|
description: "Google Cloud Platform"
|
|
298
308
|
},
|
package/dist/acronyms.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const ACRONYMS={"2D":{description:"Two-Dimensional",display:"2d"},"3D":{description:"Three-Dimensional",display:"3d"},"4D":{description:"Four-Dimensional",display:"4d"},"5G":{description:"Fifth Generation (mobile networks)"},"6G":{description:"Sixth Generation (mobile networks)"},"7G":{description:"Seventh Generation (mobile networks)"},"8G":{description:"Eighth Generation (mobile networks)"},ACID:{description:"Atomicity, Consistency, Isolation, Durability"},AITA:{description:"Am I The Asshole"},AES:{description:"Advanced Encryption Standard"},AI:{description:"Artificial Intelligence"},AJAX:{description:"Asynchronous JavaScript and XML"},API:{description:"Application Programming Interface"},AR:{description:"Augmented Reality"},ASCII:{description:"American Standard Code for Information Interchange"},ATF:{description:"Bureau of Alcohol, Tobacco, Firearms and Explosives"},ATM:{description:"Automated Teller Machine"},B2B:{description:"Business to Business"},B2C:{description:"Business to Consumer"},BATFE:{description:"Bureau of Alcohol, Tobacco, Firearms and Explosives"},BFF:{description:"Best Friends Forever"},BFFS:{description:"Best Friends Forever (plural)"},BI:{description:"Business Intelligence"},BIOS:{description:"Basic Input/Output System"},BGP:{description:"Border Gateway Protocol"},BOM:{description:"Bill of Materials / Byte Order Mark"},BYOD:{description:"Bring Your Own Device"},C2C:{description:"Consumer to Consumer"},CAGR:{description:"Compound Annual Growth Rate"},CAPTCHA:{description:"Completely Automated Public Turing test to tell Computers and Humans Apart"},CD:{description:"Continuous Delivery / Compact Disc"},CDN:{description:"Content Delivery Network"},CDP:{description:"Customer Data Platform"},CDT:{description:"Central Daylight Time"},CIA:{description:"Central Intelligence Agency"},CI:{description:"Continuous Integration"},"CI/CD":{description:"Continuous Integration/Continuous Delivery"},CIAM:{description:"Customer Identity and Access Management"},CICD:{description:"Continuous Integration Continuous Delivery",display:"CI/CD"},CLI:{description:"Command Line Interface"},CMDB:{description:"Configuration Management Database"},CORS:{description:"Cross-Origin Resource Sharing"},CPA:{description:"Certified Public Accountant"},CPU:{description:"Central Processing Unit"},CRUD:{description:"Create, Read, Update, Delete"},CSR:{description:"Certificate Signing Request / Corporate Social Responsibility"},CSS:{description:"Cascading Style Sheets"},CST:{description:"Central Standard Time"},CTA:{description:"Call To Action"},CX:{description:"Customer Experience"},DAG:{description:"Directed Acyclic Graph"},DBMS:{description:"Database Management System"},DDOS:{description:"Distributed Denial of Service",display:"DDoS"},DEA:{description:"Drug Enforcement Administration"},DEVOPS:{description:"Development Operations",display:"DevOps"},DEVENV:{description:"DevEnv",display:"DevEnv"},DIRENV:{description:"DirEnv",display:"DirEnv"},DHS:{description:"Department of Homeland Security"},DNC:{description:"Democratic National Committee / Do Not Call"},DNS:{description:"Domain Name System"},DNSSEC:{description:"Domain Name System Security Extensions"},DOD:{description:"Department of Defense",display:"DoD"},DOJ:{description:"Department of Justice",display:"DoJ"},DOT:{description:"Department of Transportation",display:"DoT"},DOM:{description:"Document Object Model"},DR:{description:"Disaster Recovery"},DRM:{description:"Digital Rights Management"},DSN:{description:"Data Source Name"},DWH:{description:"Data Warehouse"},E2E:{description:"End to End"},EAI:{description:"Enterprise Application Integration"},EDT:{description:"Eastern Daylight Time"},EEA:{description:"European Economic Area"},EKS:{description:"Elastic Kubernetes Service"},EOF:{description:"End Of File"},EOD:{description:"End Of Day / Explosive Ordnance Disposal"},EPA:{description:"Environmental Protection Agency"},ER:{description:"Emergency Room / Entity Relationship"},EST:{description:"Eastern Standard Time"},ETC:{description:"Et Cetera"},ETL:{description:"Extract, Transform, Load"},EULA:{description:"End User License Agreement"},FAQ:{description:"Frequently Asked Questions"},FBI:{description:"Federal Bureau of Investigation"},FCC:{description:"Federal Communications Commission"},FDA:{description:"Food and Drug Administration"},FIDO:{description:"Fast IDentity Online"},FLOTUS:{description:"First Lady of the United States"},FQDN:{description:"Fully Qualified Domain Name"},FTC:{description:"Federal Trade Commission"},FTP:{description:"File Transfer Protocol"},FAAS:{description:"Function as a Service",display:"FaaS"},GCP:{description:"Google Cloud Platform"},GDPR:{description:"General Data Protection Regulation"},GMT:{description:"Greenwich Mean Time"},GOP:{description:"Grand Old Party"},GPU:{description:"Graphics Processing Unit"},GUID:{description:"Globally Unique Identifier"},GUI:{description:"Graphical User Interface"},GZIP:{description:"GNU Zip"},HCI:{description:"Human Computer Interaction / Hyper-Converged Infrastructure"},HDD:{description:"Hard Disk Drive"},HDFS:{description:"Hadoop Distributed File System"},HHS:{description:"Health and Human Services"},HIPAA:{description:"Health Insurance Portability and Accountability Act"},HMAC:{description:"Hash-based Message Authentication Code"},HOTP:{description:"HMAC-based One-Time Password"},HSM:{description:"Hardware Security Module"},HTML:{description:"HyperText Markup Language"},HTTP:{description:"HyperText Transfer Protocol (HTTP)"},"HTTP/2":{description:"HyperText Transfer Protocol Version 2 (HTTP/2)"},"HTTP/2.0":{description:"HyperText Transfer Protocol Version 2 (HTTP/2)",display:"HTTP2"},HTTP2:{description:"HyperText Transfer Protocol Version 2 (HTTP/2)",display:"HTTP2"},"HTTP2.0":{description:"HyperText Transfer Protocol Version 2 (HTTP/2)",display:"HTTP2"},"HTTP/3":{description:"HyperText Transfer Protocol Version 3 (HTTP/3)"},"HTTP/3.0":{description:"HyperText Transfer Protocol Version 3 (HTTP/3)",display:"HTTP3"},HTTP3:{description:"HyperText Transfer Protocol Version 3 (HTTP/3)",display:"HTTP3"},"HTTP3.0":{description:"HyperText Transfer Protocol Version 3 (HTTP/3)",display:"HTTP3"},HTTPS:{description:"HyperText Transfer Protocol Secure (HTTPS)"},"HTTPS/2":{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)"},"HTTPS/2.0":{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)",display:"HTTPS2"},HTTPS2:{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)",display:"HTTPS2"},"HTTPS2.0":{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)",display:"HTTPS2"},"HTTPS/3":{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)"},"HTTPS/3.0":{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)",display:"HTTPS3"},HTTPS3:{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)",display:"HTTPS3"},"HTTPS3.0":{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)",display:"HTTPS3"},IAM:{description:"Identity and Access Management"},IAMM:{description:"Identity and Access Management and Monitoring"},IAMT:{description:"Identity and Access Management Tool"},IAAS:{description:"Infrastructure as a Service",display:"IaaS"},ID:{description:"Identifier",display:"Id"},IFTTT:{description:"If This Then That"},IMAP:{description:"Internet Message Access Protocol"},IP:{description:"Internet Protocol"},IPFS:{description:"InterPlanetary File System"},IPS:{description:"Intrusion Prevention System"},IQ:{description:"Intelligence Quotient",display:"IQ"},IO:{description:"Input/Output"},IOT:{description:"Internet of Things",display:"IoT"},JSON:{description:"JavaScript Object Notation"},JSONP:{description:"JSON with Padding"},JWT:{description:"JSON Web Token"},K8S:{description:"Kubernetes",display:"K8s"},KMS:{description:"Key Management Service"},KPI:{description:"Key Performance Indicator"},KV:{description:"Key Value"},LAN:{description:"Local Area Network"},LHS:{description:"Left Hand Side"},LPGA:{description:"Ladies Professional Golf Association"},LXC:{description:"Linux Containers"},MDT:{description:"Mountain Daylight Time"},MFA:{description:"Multi-Factor Authentication"},ML:{description:"Machine Learning"},MLB:{description:"Major League Baseball"},MLOps:{description:"Machine Learning Operations"},MST:{description:"Mountain Standard Time"},MVC:{description:"Model View Controller"},MVP:{description:"Minimum Viable Product / Most Valuable Player"},NAIA:{description:"National Association of Intercollegiate Athletics"},NAS:{description:"Network Attached Storage"},NASCAR:{description:"National Association for Stock Car Auto Racing"},NASA:{description:"National Aeronautics and Space Administration"},NAT:{description:"Network Address Translation"},NBA:{description:"National Basketball Association"},NCAA:{description:"National Collegiate Athletic Association"},NDA:{description:"Non-Disclosure Agreement"},NFS:{description:"Network File System"},NHL:{description:"National Hockey League"},NIST:{description:"National Institute of Standards and Technology"},NLP:{description:"Natural Language Processing"},NPS:{description:"Net Promoter Score"},NRA:{description:"National Rifle Association"},NSFW:{description:"Not Safe For Work"},NX:{description:"Nx",display:"Nx"},OCR:{description:"Optical Character Recognition"},OEM:{description:"Original Equipment Manufacturer"},OKR:{description:"Objectives and Key Results"},OLAP:{description:"Online Analytical Processing"},OLTP:{description:"Online Transaction Processing"},OOP:{description:"Object Oriented Programming"},ORM:{description:"Object Relational Mapping"},OS:{description:"Operating System"},OSS:{description:"Open Source Software"},OSINT:{description:"Open Source Intelligence"},OTP:{description:"One-Time Password"},P2P:{description:"Peer to Peer"},PDP:{description:"Policy Decision Point / Product Detail Page"},PDT:{description:"Pacific Daylight Time"},PGA:{description:"Professional Golfers' Association"},POTUS:{description:"President of the United States"},PST:{description:"Pacific Standard Time"},PTO:{description:"Paid Time Off / Power Take-Off"},PAAS:{description:"Platform as a Service",display:"PaaS"},PCI:{description:"Payment Card Industry"},PKI:{description:"Public Key Infrastructure"},PP:{description:"Pages / PayPal / Percentage Points"},PWA:{description:"Progressive Web App"},PX:{description:"Pixel"},QA:{description:"Quality Assurance"},R2:{description:"R2"},RAID:{description:"Redundant Array of Independent Disks"},RAM:{description:"Random Access Memory"},RDS:{description:"Relational Database Service"},REST:{description:"Representational State Transfer"},RHS:{description:"Right Hand Side"},ROI:{description:"Return on Investment"},RPC:{description:"Remote Procedure Call"},RPA:{description:"Robotic Process Automation"},RUM:{description:"Real User Monitoring"},RSS:{description:"Really Simple Syndication"},S3:{description:"Simple Storage Service (S3)"},SAN:{description:"Storage Area Network"},SASE:{description:"Secure Access Service Edge"},SCOTUS:{description:"Supreme Court of the United States"},SDLC:{description:"Software Development Life Cycle"},SDK:{description:"Software Development Kit"},SEC:{description:"Securities and Exchange Commission"},SEO:{description:"Search Engine Optimization"},SFTP:{description:"SSH File Transfer Protocol / Secure File Transfer Protocol"},SIEM:{description:"Security Information and Event Management"},SLA:{description:"Service Level Agreement"},SMB:{description:"Server Message Block / Small and Medium Business"},SMTP:{description:"Simple Mail Transfer Protocol"},SOAP:{description:"Simple Object Access Protocol"},SOC:{description:"Security Operations Center / System on Chip"},SOA:{description:"Service Oriented Architecture"},SPDY:{description:'Speedy (pronounced "SPeeDY")'},SPF:{description:"Sender Policy Framework"},SQL:{description:"Structured Query Language"},SRV:{description:"Service"},SRE:{description:"Site Reliability Engineering"},SSH:{description:"Secure Shell"},SSDL:{description:"Secure Software Development Lifecycle"},SSO:{description:"Single Sign-On"},SSL:{description:"Secure Sockets Layer"},SSR:{description:"Server Side Rendering"},TDD:{description:"Test Driven Development"},TLD:{description:"Top Level Domain"},TLS:{description:"Transport Layer Security"},"TLS1.3":{description:"Transport Layer Security 1.3"},TOTP:{description:"Time-based One-Time Password"},TRPC:{description:"TypeScript Remote Procedure Call"},TSA:{description:"Transportation Security Administration"},TTL:{description:"Time To Live"},UDP:{description:"User Datagram Protocol"},UI:{description:"User Interface"},UID:{description:"Unique Identifier"},URI:{description:"Uniform Resource Identifier"},URL:{description:"Uniform Resource Locator"},USOPC:{description:"United States Olympic & Paralympic Committee"},USPS:{description:"United States Postal Service"},USTA:{description:"United States Tennis Association"},UTF:{description:"Unicode Transformation Format"},UTC:{description:"Coordinated Universal Time"},UUID:{description:"Universally Unique Identifier"},UX:{description:"User Experience"},VM:{description:"Virtual Machine"},VLAN:{description:"Virtual Local Area Network"},VPN:{description:"Virtual Private Network"},VPPA:{description:"Video Privacy Protection Act"},VR:{description:"Virtual Reality"},WAF:{description:"Web Application Firewall"},WAN:{description:"Wide Area Network"},WNBA:{description:"Women's National Basketball Association"},WLAN:{description:"Wireless Local Area Network"},WPA:{description:"Wi-Fi Protected Access"},XACML:{description:"eXtensible Access Control Markup Language"},XDG:{description:"Cross-Desktop Group"},XML:{description:"eXtensible Markup Language"},XSRF:{description:"Cross-Site Request Forgery"},XSS:{description:"Cross-Site Scripting"},XR:{description:"Extended Reality"},YMCA:{description:"Young Men's Christian Association"},YAML:{description:"YAML Ain't Markup Language"},YWCA:{description:"Young Women's Christian Association"},ZTA:{description:"Zero Trust Architecture"}},ACRONYM_DISPLAY=Object.fromEntries(Object.entries(ACRONYMS).map(([e,i])=>[e,i.display??e])),ACRONYM_DESCRIPTION=Object.fromEntries(Object.entries(ACRONYMS).map(([e,i])=>[e,i.description])),ACRONYM_LIST=Object.keys(ACRONYMS);
|
|
1
|
+
export const ACRONYMS={"2D":{description:"Two-Dimensional",display:"2d"},"3D":{description:"Three-Dimensional",display:"3d"},"4D":{description:"Four-Dimensional",display:"4d"},"5G":{description:"Fifth Generation (mobile networks)"},"6G":{description:"Sixth Generation (mobile networks)"},"7G":{description:"Seventh Generation (mobile networks)"},"8G":{description:"Eighth Generation (mobile networks)"},ACID:{description:"Atomicity, Consistency, Isolation, Durability"},AITA:{description:"Am I The Asshole"},AES:{description:"Advanced Encryption Standard"},AI:{description:"Artificial Intelligence"},AJAX:{description:"Asynchronous JavaScript and XML"},API:{description:"Application Programming Interface"},AR:{description:"Augmented Reality"},ASCII:{description:"American Standard Code for Information Interchange"},ATF:{description:"Bureau of Alcohol, Tobacco, Firearms and Explosives"},ATM:{description:"Automated Teller Machine"},B2B:{description:"Business to Business"},B2C:{description:"Business to Consumer"},BATFE:{description:"Bureau of Alcohol, Tobacco, Firearms and Explosives"},BFF:{description:"Best Friends Forever"},BFFS:{description:"Best Friends Forever (plural)"},BI:{description:"Business Intelligence"},BIOS:{description:"Basic Input/Output System"},BGP:{description:"Border Gateway Protocol"},BOM:{description:"Bill of Materials / Byte Order Mark"},BYOD:{description:"Bring Your Own Device"},C2C:{description:"Consumer to Consumer"},CAGR:{description:"Compound Annual Growth Rate"},CAPTCHA:{description:"Completely Automated Public Turing test to tell Computers and Humans Apart"},CD:{description:"Continuous Delivery / Compact Disc"},CDN:{description:"Content Delivery Network"},CDP:{description:"Customer Data Platform"},CDT:{description:"Central Daylight Time"},CIA:{description:"Central Intelligence Agency"},CI:{description:"Continuous Integration"},"CI/CD":{description:"Continuous Integration/Continuous Delivery"},CIAM:{description:"Customer Identity and Access Management"},CICD:{description:"Continuous Integration Continuous Delivery",display:"CI/CD"},CLI:{description:"Command Line Interface"},CMDB:{description:"Configuration Management Database"},CORS:{description:"Cross-Origin Resource Sharing"},CPA:{description:"Certified Public Accountant"},CPU:{description:"Central Processing Unit"},CRUD:{description:"Create, Read, Update, Delete"},CSR:{description:"Certificate Signing Request / Corporate Social Responsibility"},CSS:{description:"Cascading Style Sheets"},CST:{description:"Central Standard Time"},CTA:{description:"Call To Action"},CWD:{description:"Current Working Directory"},CX:{description:"Customer Experience"},DAG:{description:"Directed Acyclic Graph"},DBMS:{description:"Database Management System"},DDOS:{description:"Distributed Denial of Service",display:"DDoS"},DEA:{description:"Drug Enforcement Administration"},DEVOPS:{description:"Development Operations",display:"DevOps"},DEVENV:{description:"Devenv",display:"Devenv"},DOTENV:{description:"Dotenv (.env)",display:"Dotenv"},DIRENV:{description:"DirEnv",display:"DirEnv"},DHS:{description:"Department of Homeland Security"},DNC:{description:"Democratic National Committee / Do Not Call"},DNS:{description:"Domain Name System"},DNSSEC:{description:"Domain Name System Security Extensions"},DOD:{description:"Department of Defense",display:"DoD"},DOJ:{description:"Department of Justice",display:"DoJ"},DOT:{description:"Department of Transportation",display:"DoT"},DOM:{description:"Document Object Model"},DR:{description:"Disaster Recovery"},DRM:{description:"Digital Rights Management"},DSN:{description:"Data Source Name"},DWH:{description:"Data Warehouse"},E2E:{description:"End to End"},EAI:{description:"Enterprise Application Integration"},EDT:{description:"Eastern Daylight Time"},EEA:{description:"European Economic Area"},EKS:{description:"Elastic Kubernetes Service"},EOF:{description:"End Of File"},EOD:{description:"End Of Day / Explosive Ordnance Disposal"},EPA:{description:"Environmental Protection Agency"},ER:{description:"Emergency Room / Entity Relationship"},EST:{description:"Eastern Standard Time"},ETC:{description:"Et Cetera"},ETL:{description:"Extract, Transform, Load"},EULA:{description:"End User License Agreement"},FAQ:{description:"Frequently Asked Questions"},FBI:{description:"Federal Bureau of Investigation"},FCC:{description:"Federal Communications Commission"},FDA:{description:"Food and Drug Administration"},FIDO:{description:"Fast IDentity Online"},FLOTUS:{description:"First Lady of the United States"},FQDN:{description:"Fully Qualified Domain Name"},FTC:{description:"Federal Trade Commission"},FTP:{description:"File Transfer Protocol"},FAAS:{description:"Function as a Service",display:"FaaS"},GC:{description:"Garbage Collection"},GCP:{description:"Google Cloud Platform"},GDPR:{description:"General Data Protection Regulation"},GMT:{description:"Greenwich Mean Time"},GOP:{description:"Grand Old Party"},GPU:{description:"Graphics Processing Unit"},GUID:{description:"Globally Unique Identifier"},GUI:{description:"Graphical User Interface"},GZIP:{description:"GNU Zip"},HCI:{description:"Human Computer Interaction / Hyper-Converged Infrastructure"},HDD:{description:"Hard Disk Drive"},HDFS:{description:"Hadoop Distributed File System"},HHS:{description:"Health and Human Services"},HIPAA:{description:"Health Insurance Portability and Accountability Act"},HMAC:{description:"Hash-based Message Authentication Code"},HOTP:{description:"HMAC-based One-Time Password"},HSM:{description:"Hardware Security Module"},HTML:{description:"HyperText Markup Language"},HTTP:{description:"HyperText Transfer Protocol (HTTP)"},"HTTP/2":{description:"HyperText Transfer Protocol Version 2 (HTTP/2)"},"HTTP/2.0":{description:"HyperText Transfer Protocol Version 2 (HTTP/2)",display:"HTTP2"},HTTP2:{description:"HyperText Transfer Protocol Version 2 (HTTP/2)",display:"HTTP2"},"HTTP2.0":{description:"HyperText Transfer Protocol Version 2 (HTTP/2)",display:"HTTP2"},"HTTP/3":{description:"HyperText Transfer Protocol Version 3 (HTTP/3)"},"HTTP/3.0":{description:"HyperText Transfer Protocol Version 3 (HTTP/3)",display:"HTTP3"},HTTP3:{description:"HyperText Transfer Protocol Version 3 (HTTP/3)",display:"HTTP3"},"HTTP3.0":{description:"HyperText Transfer Protocol Version 3 (HTTP/3)",display:"HTTP3"},HTTPS:{description:"HyperText Transfer Protocol Secure (HTTPS)"},"HTTPS/2":{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)"},"HTTPS/2.0":{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)",display:"HTTPS2"},HTTPS2:{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)",display:"HTTPS2"},"HTTPS2.0":{description:"HyperText Transfer Protocol Secure Version 2 (HTTPS/2)",display:"HTTPS2"},"HTTPS/3":{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)"},"HTTPS/3.0":{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)",display:"HTTPS3"},HTTPS3:{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)",display:"HTTPS3"},"HTTPS3.0":{description:"HyperText Transfer Protocol Secure Version 3 (HTTPS/3)",display:"HTTPS3"},IAM:{description:"Identity and Access Management"},IAMM:{description:"Identity and Access Management and Monitoring"},IAMT:{description:"Identity and Access Management Tool"},IAAS:{description:"Infrastructure as a Service",display:"IaaS"},ID:{description:"Identifier",display:"Id"},IFTTT:{description:"If This Then That"},IMAP:{description:"Internet Message Access Protocol"},IP:{description:"Internet Protocol"},IPFS:{description:"InterPlanetary File System"},IPS:{description:"Intrusion Prevention System"},IQ:{description:"Intelligence Quotient",display:"IQ"},IO:{description:"Input/Output"},IOT:{description:"Internet of Things",display:"IoT"},JSON:{description:"JavaScript Object Notation"},JSONP:{description:"JSON with Padding"},JWT:{description:"JSON Web Token"},K8S:{description:"Kubernetes",display:"K8s"},KMS:{description:"Key Management Service"},KPI:{description:"Key Performance Indicator"},KV:{description:"Key Value"},LAN:{description:"Local Area Network"},LHS:{description:"Left Hand Side"},LPGA:{description:"Ladies Professional Golf Association"},LXC:{description:"Linux Containers"},MDT:{description:"Mountain Daylight Time"},MFA:{description:"Multi-Factor Authentication"},ML:{description:"Machine Learning"},MLB:{description:"Major League Baseball"},MLOps:{description:"Machine Learning Operations"},MST:{description:"Mountain Standard Time"},MVC:{description:"Model View Controller"},MVP:{description:"Minimum Viable Product / Most Valuable Player"},NAIA:{description:"National Association of Intercollegiate Athletics"},NAS:{description:"Network Attached Storage"},NASCAR:{description:"National Association for Stock Car Auto Racing"},NASA:{description:"National Aeronautics and Space Administration"},NAT:{description:"Network Address Translation"},NBA:{description:"National Basketball Association"},NCAA:{description:"National Collegiate Athletic Association"},NDA:{description:"Non-Disclosure Agreement"},NFS:{description:"Network File System"},NHL:{description:"National Hockey League"},NIST:{description:"National Institute of Standards and Technology"},NLP:{description:"Natural Language Processing"},NPS:{description:"Net Promoter Score"},NRA:{description:"National Rifle Association"},NSFW:{description:"Not Safe For Work"},NX:{description:"Nx",display:"Nx"},OCR:{description:"Optical Character Recognition"},OEM:{description:"Original Equipment Manufacturer"},OKR:{description:"Objectives and Key Results"},OLAP:{description:"Online Analytical Processing"},OLTP:{description:"Online Transaction Processing"},OOP:{description:"Object Oriented Programming"},ORM:{description:"Object Relational Mapping"},OS:{description:"Operating System"},OSS:{description:"Open Source Software"},OSINT:{description:"Open Source Intelligence"},OTP:{description:"One-Time Password"},P2P:{description:"Peer to Peer"},PDP:{description:"Policy Decision Point / Product Detail Page"},PDT:{description:"Pacific Daylight Time"},PGA:{description:"Professional Golfers' Association"},POTUS:{description:"President of the United States"},PST:{description:"Pacific Standard Time"},PTO:{description:"Paid Time Off / Power Take-Off"},PAAS:{description:"Platform as a Service",display:"PaaS"},PCI:{description:"Payment Card Industry"},PKI:{description:"Public Key Infrastructure"},PP:{description:"Pages / PayPal / Percentage Points"},PWA:{description:"Progressive Web App"},PX:{description:"Pixel"},QA:{description:"Quality Assurance"},R2:{description:"R2"},RAID:{description:"Redundant Array of Independent Disks"},RAM:{description:"Random Access Memory"},RDS:{description:"Relational Database Service"},REST:{description:"Representational State Transfer"},RHS:{description:"Right Hand Side"},ROI:{description:"Return on Investment"},RPC:{description:"Remote Procedure Call"},RPA:{description:"Robotic Process Automation"},RUM:{description:"Real User Monitoring"},RSS:{description:"Really Simple Syndication"},S3:{description:"Simple Storage Service (S3)"},SAN:{description:"Storage Area Network"},SASE:{description:"Secure Access Service Edge"},SCOTUS:{description:"Supreme Court of the United States"},SDLC:{description:"Software Development Life Cycle"},SDK:{description:"Software Development Kit"},SEC:{description:"Securities and Exchange Commission"},SEO:{description:"Search Engine Optimization"},SFTP:{description:"SSH File Transfer Protocol / Secure File Transfer Protocol"},SIEM:{description:"Security Information and Event Management"},SLA:{description:"Service Level Agreement"},SMB:{description:"Server Message Block / Small and Medium Business"},SMTP:{description:"Simple Mail Transfer Protocol"},SOAP:{description:"Simple Object Access Protocol"},SOC:{description:"Security Operations Center / System on Chip"},SOA:{description:"Service Oriented Architecture"},SPDY:{description:'Speedy (pronounced "SPeeDY")'},SPF:{description:"Sender Policy Framework"},SQL:{description:"Structured Query Language"},SRV:{description:"Service"},SRE:{description:"Site Reliability Engineering"},SSH:{description:"Secure Shell"},SSDL:{description:"Secure Software Development Lifecycle"},SSO:{description:"Single Sign-On"},SSL:{description:"Secure Sockets Layer"},SSR:{description:"Server Side Rendering"},TDD:{description:"Test Driven Development"},TLD:{description:"Top Level Domain"},TLS:{description:"Transport Layer Security"},"TLS1.3":{description:"Transport Layer Security 1.3"},TOTP:{description:"Time-based One-Time Password"},TRPC:{description:"TypeScript Remote Procedure Call"},TSA:{description:"Transportation Security Administration"},TTL:{description:"Time To Live"},UDP:{description:"User Datagram Protocol"},UI:{description:"User Interface"},UID:{description:"Unique Identifier"},URI:{description:"Uniform Resource Identifier"},URL:{description:"Uniform Resource Locator"},USOPC:{description:"United States Olympic & Paralympic Committee"},USPS:{description:"United States Postal Service"},USTA:{description:"United States Tennis Association"},UTF:{description:"Unicode Transformation Format"},UTC:{description:"Coordinated Universal Time"},UUID:{description:"Universally Unique Identifier"},UX:{description:"User Experience"},VM:{description:"Virtual Machine"},VLAN:{description:"Virtual Local Area Network"},VPN:{description:"Virtual Private Network"},VPPA:{description:"Video Privacy Protection Act"},VR:{description:"Virtual Reality"},WAF:{description:"Web Application Firewall"},WAN:{description:"Wide Area Network"},WNBA:{description:"Women's National Basketball Association"},WLAN:{description:"Wireless Local Area Network"},WPA:{description:"Wi-Fi Protected Access"},XACML:{description:"eXtensible Access Control Markup Language"},XDG:{description:"Cross-Desktop Group"},XML:{description:"eXtensible Markup Language"},XSRF:{description:"Cross-Site Request Forgery"},XSS:{description:"Cross-Site Scripting"},XR:{description:"Extended Reality"},YMCA:{description:"Young Men's Christian Association"},YAML:{description:"YAML Ain't Markup Language"},YWCA:{description:"Young Women's Christian Association"},ZTA:{description:"Zero Trust Architecture"}},ACRONYM_DISPLAY=Object.fromEntries(Object.entries(ACRONYMS).map(([e,i])=>[e,i.display??e])),ACRONYM_DESCRIPTION=Object.fromEntries(Object.entries(ACRONYMS).map(([e,i])=>[e,i.description])),ACRONYM_LIST=Object.keys(ACRONYMS);
|
package/dist/title-case.cjs
CHANGED
|
@@ -3,26 +3,29 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.LOWER_CASE_WHEN_NOT_FIRST = exports.
|
|
6
|
+
exports.LOWER_CASE_WHEN_NOT_FIRST = exports.FORMAT_MAPPING = void 0;
|
|
7
7
|
exports.isTitleCase = isTitleCase;
|
|
8
8
|
exports.titleCase = titleCase;
|
|
9
9
|
var _acronyms = require("./acronyms.cjs");
|
|
10
10
|
var _getWords = require("./get-words.cjs");
|
|
11
11
|
var _upperCaseFirst = require("./upper-case-first.cjs");
|
|
12
|
-
const
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}),
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
12
|
+
const FORMAT_MAPPING = exports.FORMAT_MAPPING = _acronyms.ACRONYM_LIST.reduce((s, e) => (s[e.toUpperCase()] = {
|
|
13
|
+
description: _acronyms.ACRONYMS[e]?.description || _acronyms.ACRONYMS[e]?.display || e,
|
|
14
|
+
display: _acronyms.ACRONYMS[e]?.display || e
|
|
15
|
+
}, s), {
|
|
16
|
+
CSPELL: {
|
|
17
|
+
description: "CSpell",
|
|
18
|
+
display: "CSpell"
|
|
19
|
+
},
|
|
20
|
+
ESLINT: {
|
|
21
|
+
description: "ESLint",
|
|
22
|
+
display: "ESLint"
|
|
23
|
+
}
|
|
19
24
|
}),
|
|
20
25
|
LOWER_CASE_WHEN_NOT_FIRST = exports.LOWER_CASE_WHEN_NOT_FIRST = ["a", "an", "the", "is", "are", "of", "and", "to", "in", "for", "on", "with", "as", "at", "by"];
|
|
21
|
-
function isTitleCase(
|
|
22
|
-
return
|
|
26
|
+
function isTitleCase(s) {
|
|
27
|
+
return s ? s.split(/[\s\-_]+/).filter(Boolean).every((i, t) => FORMAT_MAPPING[i.toUpperCase()] || t > 0 && LOWER_CASE_WHEN_NOT_FIRST.includes(i.toLowerCase()) && i === i.toLowerCase() ? !0 : /^[A-Z][a-z0-9]*$/.test(i)) : !1;
|
|
23
28
|
}
|
|
24
|
-
function titleCase(
|
|
25
|
-
|
|
26
|
-
const r = i => (0, _getWords.getWords)(i).filter(Boolean).map(s => s.toLowerCase()).map((s, a) => !e.skipLowerCaseWhenNotFirst && LOWER_CASE_WHEN_NOT_FIRST.includes(s.toLowerCase()) && a > 0 ? s.toLowerCase() : !e.skipFormatMapping && DISPLAY_MAPPING[s.toUpperCase()] ? e.useDescriptions !== !1 ? DESCRIPTION_MAPPING[s.toUpperCase()] : DISPLAY_MAPPING[s.toUpperCase()] : e.mapping && Object.keys(e.mapping).includes(s.toLowerCase()) ? e.mapping[s.toLowerCase()] : `${(0, _upperCaseFirst.upperCaseFirst)(s.toLowerCase())}`).join(" ");
|
|
27
|
-
return t.split(/\s+-\s+/).map(i => r(i)).join(" - ");
|
|
29
|
+
function titleCase(s, e = {}) {
|
|
30
|
+
return isTitleCase(s) || s === void 0 ? s : s.split(/\s+-\s+/).map(i => (0, _getWords.getWords)(i).filter(Boolean).map((t, n) => !e.skipLowerCaseWhenNotFirst && LOWER_CASE_WHEN_NOT_FIRST.includes(t.toLowerCase()) && n > 0 ? t.toLowerCase() : !e.skipFormatMapping && FORMAT_MAPPING[t.toUpperCase()] ? e.useDescriptions !== !1 ? FORMAT_MAPPING[t.toUpperCase()]?.description : FORMAT_MAPPING[t.toUpperCase()]?.display : e.mapping && Object.keys(e.mapping).includes(t.toUpperCase()) ? e.mapping[t.toUpperCase()] : `${(0, _upperCaseFirst.upperCaseFirst)(t)}`).join(" ")).join(" - ");
|
|
28
31
|
}
|
package/dist/title-case.d.ts
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
|
|
1
|
+
export declare const FORMAT_MAPPING: Record<string, {
|
|
2
|
+
description: string;
|
|
3
|
+
display: string;
|
|
4
|
+
}>;
|
|
3
5
|
export declare const LOWER_CASE_WHEN_NOT_FIRST: string[];
|
|
4
6
|
export interface TitleCaseOptions {
|
|
5
7
|
/**
|
|
6
8
|
* If true, skip the format mapping. This will skip the conversion of known acronyms to their upper case form.
|
|
7
9
|
*
|
|
8
10
|
* @remarks
|
|
9
|
-
* The current list of word format mappings is stored in {@link
|
|
11
|
+
* The current list of word format mappings is stored in {@link FORMAT_MAPPING}.
|
|
10
12
|
*
|
|
11
13
|
* @defaultValue false
|
|
12
14
|
*/
|
package/dist/title-case.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{ACRONYM_LIST as
|
|
1
|
+
import{ACRONYM_LIST as p,ACRONYMS as r}from"./acronyms";import{getWords as a}from"./get-words";import{upperCaseFirst as o}from"./upper-case-first";export const FORMAT_MAPPING=p.reduce((s,e)=>(s[e.toUpperCase()]={description:r[e]?.description||r[e]?.display||e,display:r[e]?.display||e},s),{CSPELL:{description:"CSpell",display:"CSpell"},ESLINT:{description:"ESLint",display:"ESLint"}}),LOWER_CASE_WHEN_NOT_FIRST=["a","an","the","is","are","of","and","to","in","for","on","with","as","at","by"];export function isTitleCase(s){return s?s.split(/[\s\-_]+/).filter(Boolean).every((i,t)=>FORMAT_MAPPING[i.toUpperCase()]||t>0&&LOWER_CASE_WHEN_NOT_FIRST.includes(i.toLowerCase())&&i===i.toLowerCase()?!0:/^[A-Z][a-z0-9]*$/.test(i)):!1}export function titleCase(s,e={}){return isTitleCase(s)||s===void 0?s:s.split(/\s+-\s+/).map(i=>a(i).filter(Boolean).map((t,n)=>!e.skipLowerCaseWhenNotFirst&&LOWER_CASE_WHEN_NOT_FIRST.includes(t.toLowerCase())&&n>0?t.toLowerCase():!e.skipFormatMapping&&FORMAT_MAPPING[t.toUpperCase()]?e.useDescriptions!==!1?FORMAT_MAPPING[t.toUpperCase()]?.description:FORMAT_MAPPING[t.toUpperCase()]?.display:e.mapping&&Object.keys(e.mapping).includes(t.toUpperCase())?e.mapping[t.toUpperCase()]:`${o(t)}`).join(" ")).join(" - ")}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stryke/string-format",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A package containing utility functions to transform strings into various formats.",
|
|
6
6
|
"repository": {
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
},
|
|
11
11
|
"private": false,
|
|
12
12
|
"publishConfig": { "access": "public" },
|
|
13
|
-
"dependencies": { "@stryke/helpers": "^0.7.2", "@stryke/types": "^0.8.
|
|
13
|
+
"dependencies": { "@stryke/helpers": "^0.7.2", "@stryke/types": "^0.8.9" },
|
|
14
14
|
"devDependencies": {},
|
|
15
15
|
"sideEffects": false,
|
|
16
16
|
"files": ["dist/**/*"],
|
|
@@ -333,5 +333,5 @@
|
|
|
333
333
|
"main": "./dist/index.cjs",
|
|
334
334
|
"module": "./dist/index.mjs",
|
|
335
335
|
"types": "./dist/index.d.ts",
|
|
336
|
-
"gitHead": "
|
|
336
|
+
"gitHead": "f8abb224a6b6540e442cc664bbb2cf1273b2be2b"
|
|
337
337
|
}
|