Why

Powerful

Unlike other syntax highlighters, Photon works on any platform, both browser-side and server-side.

Alternatives that run on the browser do not work optimally. This is because of the technical difficulties involved in understanding as many languages and taking up as little space as possible. Over time, as languages add new features, these syntax highlighters face new challenges that are sometimes impossible to solve.

Photon uses powerful parsers to lexically analyze the code and thus understand the syntax of the language used. This process guarantees a very accurate result. Check out the getting-started/comparison page to see how this process affects the result.

Due to this accuracy, you can create/modify themes to tune the color of each token and obtain full control over the syntax highlighting.

Ownership

Do you remember the times when people used to upload their pages to Geocities?

Do you remember Google Code?

Whatever the response, you may be trying to save your favorite vines due to the closure of the Platform (if you're still on time).

Not to mention Twitter whose future does not look very good.

Much of the content on the internet ends up disappearing when the platforms that host it disappear.

That is why in Photon we want you to be the owner of your content. Your snippets will not disappear from our service because we do not store anything. You will not have to migrate anything in the future. You control your snippets and their destiny.

Semantics

We try to make our service use web standards as accurately as possible, making use of best practices.

For example, we use the HTML <figure> (link) element to wrap the snippet, as indicated by the HTML standard. We also use the HTML <code> (link) and <samp> (link) elements to differenciate the input (code) from the output (sample).

Other HTML elements and CSS selectors have been carefully selected to promote the correct markup on the web.