Skip to content

Instantly share code, notes, and snippets.

View markrowi's full-sized avatar

Mark Rowi Dizon markrowi

View GitHub Profile
@jukben
jukben / CachedLayer.js
Last active December 12, 2022 20:07
Custom Layer for react-leafleat with naive cache mechanism
import { withLeaflet, GridLayer } from "react-leaflet";
import L from "leaflet";
class Grid extends GridLayer {
createLeafletElement() {
const { url, cacheName } = this.props;
const Layer = L.TileLayer.extend({
createTile: (coords, done) => {
const { x, y, z } = coords;
@jahe
jahe / spring-boot-cheatsheet.java
Last active September 3, 2025 14:31
Spring Boot Cheatsheet
// Enable component-scanning and auto-configuration with @SpringBootApplication Annotation
// It combines @Configuration + @ComponentScan + @EnableAutoConfiguration
@SpringBootApplication
public class FooApplication {
public static void main(String[] args) {
// Bootstrap the application
SpringApplication.run(FooApplication.class, args);
}
}