Skip to content

Instantly share code, notes, and snippets.

View ugurcoskn's full-sized avatar
🏆
Focusing

Uğur Coşkun ugurcoskn

🏆
Focusing
View GitHub Profile
@degitgitagitya
degitgitagitya / .env
Last active August 6, 2025 14:03
Next JS + Next Auth + Keycloak + AutoRefreshToken
# KEYCLOAK BASE URL
KEYCLOAK_BASE_URL=
# KEYCLOAK CLIENT SECRET
KEYCLOAK_CLIENT_SECRET=
# KEYCLOAK CLIENT ID
KEYCLOAK_CLIENT_ID=
# BASE URL FOR NEXT AUTH
@croxton
croxton / leaflet_custom_zoom_levels.js
Last active May 20, 2022 16:13
Leaflet custom zoom levels
/*
Most map tile providers use 256px square tiles so Leaflet's basic zoom algorithm looks like this:
256 * Math.pow(2, zoom);
If you're working with vector layers you can extend one of leaflet's default CRSs
and make it return tile sizes in smaller increments. This can be very helpful when using
fitBounds() with layer groups, so the zoomed group fits better within the map bounds:
E.g., extending L.CRS.EPSG3857 (the default CRS):