Is this code snippet styled with CSS? If so, any ideas on how it was styled this way?

This page summarizes the projects mentioned and recommended in the original post on /r/css

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • WorkOS - The modern identity platform for B2B SaaS
  • carbon

    :black_heart: Create and share beautiful images of your source code

  • Yeah, if it really was just about a few lines then pure CSS would be doable if it was just for like a small blog post or something. Someone also suggested Carbon which is probably the easiest and best looking solution to the problem.

  • Highlight.js

    JavaScript syntax highlighter with language auto-detection and zero dependencies.

  • For the record, I'm not saying "just use a library" is an appropriate answer to the question either. I think a better answer would be to explain the complexities involved in syntax highlighting and the purpose and why you wouldn't try to do it with plain CSS. Then suggest, that if you want to do this, here's a great library you can use!

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
  • PrismJS

    Lightweight, robust, elegant syntax highlighting.

  • vscode-remark

    Lint and format markdown code with remark

  • gatsby-remark-vscode

    Gatsby plugin to provide VS Code’s syntax highlighting to Markdown code fences

  • react-syntax-highlighter

    syntax highlighting component for react with prismjs or highlightjs ast using inline styles

  • react-native-syntax-highlighter

    a syntax highlighter for react native using https://github.com/conorhastings/react-syntax-highlighter under the hood

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
  • refractor

    Lightweight, robust, elegant virtual syntax highlighting using Prism

  • lowlight

    Virtual syntax highlighting for virtual DOMs and non-HTML things

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts