Results for “Text handling & Unicode”
Small, practical examples. Search by task or narrow things down below.
Offer a downloadable text file
HTML: The download attribute supplies a filename for this same-document data URL.
HTML✓ Tested
Override context in a nested section
Override context in a nested section with a small React component and explicit browser behavior.
React✓ Tested
Parse JSON text
Read a JavaScript object from JSON text.
JavaScript✓ Tested
Print a fixed text buffer
Arduino / C: Print a fixed text buffer on an Uno with the Serial Monitor set to 9600 baud.
Arduino / C✓ Tested
Print text containing percent characters literally
Bash Scripts: Never use untrusted text as the printf format string.
Bash Scripts✓ Tested
Process a text file one line at a time
Java: Use a buffered reader to avoid loading a large file into memory.
Java✓ Tested
Provide alternative text for an informative image
Provide alternative text for an informative image with a standalone Angular component and explicit browser behavior.
Angular✓ Tested
Read a JSONB field as text
Extract a nested value from a JSON document.
jsonb✓ Tested
Read a text field’s value
jQuery: Learn how to read a text field’s value in a complete browser example.
jQuery✓ Tested
Read a text file
Open a UTF-8 text file and read its contents. A context manager closes the file automatically, even if reading fails.
file✓ Tested
Read a text file
Load a small text file into a C# string.
C#✓ Tested
Read a value from context
Read a value from context with a small React component and explicit browser behavior.
React✓ Tested