ifc-language-server/node_modules/string-width
Ryan Schultz 8afacf268a Implemented a working Language Server Protocol (LSP) for IFC files with:
- Hover provider showing entity information and type
- Go-to-definition (F12) for entity references
- Basic IFC file validation (ISO-10303-21 header check)
- Entity parsing with regex-based detection
- Proper CommonJS module system (avoiding ES module issues)

This replaces the broken baseline from ifc-developer-tools which had:
- Non-functional ES module configuration
- Circular dependency issues
- Parser crashes
- Non-working PositionVisitor

Built on Microsoft's LSP example template for a clean, maintainable foundation.

Next: Add hierarchical entity dependency tree in hover tooltip."
2025-12-07 10:20:07 -06:00
..
index.d.ts Implemented a working Language Server Protocol (LSP) for IFC files with: 2025-12-07 10:20:07 -06:00
index.js Implemented a working Language Server Protocol (LSP) for IFC files with: 2025-12-07 10:20:07 -06:00
license Implemented a working Language Server Protocol (LSP) for IFC files with: 2025-12-07 10:20:07 -06:00
package.json Implemented a working Language Server Protocol (LSP) for IFC files with: 2025-12-07 10:20:07 -06:00
readme.md Implemented a working Language Server Protocol (LSP) for IFC files with: 2025-12-07 10:20:07 -06:00

string-width

Get the visual width of a string - the number of columns required to display it

Some Unicode characters are fullwidth and use double the normal width. ANSI escape codes are stripped and doesn't affect the width.

Useful to be able to measure the actual width of command-line output.

Install

$ npm install string-width

Usage

const stringWidth = require('string-width');

stringWidth('a');
//=> 1

stringWidth('古');
//=> 2

stringWidth('\u001B[1m古\u001B[22m');
//=> 2

Get professional support for this package with a Tidelift subscription
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.