package
JavaScript library for the WordPress.com Photon image manipulation service.
npm install photonGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Tagged topics.
yuliyan
yuliyan.slavchev@gmail.com
a8c
invoices@automattic.com
blowery
ben@blowery.org
ehg_
chris@ehg.sh
sgomes
mail@sgomes.io
tyxla
tyxla@abv.bg
saroshaga
sarosh.aga@automattic.com
nejclovrencic
nejc.lovrencic@gmail.com
sirbrillig
payton@foolord.com
chriszarate
chris@zarate.org
robersongomes
robersonccgomes@gmail.com
johngodley
johng75@gmail.com
jeherve
jeremy@tagada.hu
daledupreez-a8c
dale@automattic.com
t2dw4t
todd.wright@automattic.com
luismulinari
luis.mulinari@gmail.com
andrea-sdl
andrea.grassi@automattic.com
elazzabi
elazzabi.ahmed@gmail.com
fmfernandes
fernando.fernandes@automattic.com
sirreal
jon.surrell@gmail.com
wwa
volodymyr@wildwolf.name
chihsuan
chihsuan.tw@gmail.com
manzoorwanijk
manzoorwani.jk@gmail.com
msurdi-a8c
matias.emanuel.surdi@automattic.com
newspack-npm
newspack@a8c.com
dsmartg
derek.smart@automattic.com
kthai15
kavin.keratikasama@automattic.com
bgrgicak
berislav.grgicak@gmail.com
robertsreberski_a8c
robert.sreberski@automattic.com
artpi
artur.piszek@gmail.com
gmjuhasz
jugergo@gmail.com
borkweb
borkweb@gmail.com
kat3samsin
kat3samsin@gmail.com
brunobasto
b.basto@gmail.com
dhenridev
douglas.henri@automattic.com
mrmurphy
m@mrmurphy.dev
wpvip-bot
platform+npm@wpvip.com
etobiesen
e.tobiesen@gmail.com
alshakero
omar@omaralshaker.com
arthur791004
arthur791004@gmail.com
dilirity
peter.petrov89@gmail.com
anandnalya
anand.nalya@gmail.com
arcangelinis
anthony.arcangelini@gmail.com
retrofox
rdsuarez@gmail.com
iamchughmayank
mayank.chugh@automattic.com
simison
mikael@ihminen.org
fredrikekelund
fredrik@fredrik.computer
griffithchen
griffith.chen@automattic.com
mdawaffe
michael.d.adams@gmail.com
jboland8
josh.boland@automattic.com
chriskmnds
chriskmnds@gmail.com
oandregal
ola@oandre.gal
galatanovidiu
galatanovidiu@gmail.com
kangzj
kangzjnet@gmail.com
_mirka_
lena@jaguchi.com
aduth
andrew@andrewduthie.com
ebuccelli
emanuele.buccelli@automattic.com
tootallnate
nathan@tootallnate.net
dmsnell
dennis.snell@automattic.com
Estimated unpacked size across 7 packages.
185.2 kB
Includes dependencies.
5 direct dependencies.
JavaScript library for the WordPress.com Photon image manipulation service.
Photon.js requires support for the standard URL and URLSearchParams APIs. Be sure to use a polyfill if you're targetting environments without support for them. This includes old browsers, such as Internet Explorer 11, and old versions of Node.js (5 or older).
Install via npm:
yarn add photonImport the photon method into your module.
For CommonJS:
const photon = require( 'photon' );For ES Modules:
import photon from 'photon';Then use the imported method to generate Photon URLs:
const url = photon( 'https://wordpress.org/style/images/wporg-logo.svg' );
console.log( url );
// https://i1.wp.com/wordpress.org/style/images/wporg-logo.svg?ssl=1GPL-2.0-or-later – Copyright 2014-2019 Automattic