Skip to content

Instantly share code, notes, and snippets.

View skelz0r's full-sized avatar
:shipit:
🤷

Delmaire Loïc skelz0r

:shipit:
🤷
View GitHub Profile
@skelz0r
skelz0r / dynamic-modal.md
Created October 25, 2025 10:03
Features examples

I would like to allow a controller to define the size of the modal dynamically.

Currently, the modal is defined in app/views/shared/_modal.html.erb There is a turbo-frame tag with the id main-modal-content for the general modal.

An example of a response that the server can make: app/views/instruction/refuse_authorization_requests/new.html.erb

Note that there is the same main-modal-content turbo-frame.

@skelz0r
skelz0r / feature.md
Created October 24, 2025 15:52
Example workflow

The goal is to migrate all static models to the database.

We will start with the DataProvider model.

All of its attributes are defined in config/data_providers.yml.

The file format is:

@skelz0r
skelz0r / README.md
Created October 24, 2025 14:24
llm-feature with o1-pro

LLM feature with o1-pro

  • llm-feature: the bin
  • prd.txt.erb: PRD template
  • code.txt.erb: code template
  • project-context.xml: context regarding the project
  • llm-feature.txt: an example of the feature

Usage:

@skelz0r
skelz0r / algorithme.rb
Last active February 16, 2025 12:16
Extraction liens capitalistiques depuis la liasse fiscale d'API Entreprise
siren='130025265'
year='2023'
liasses_fiscales = lookup_data("/v3/dgfip/unites_legales/#{siren}/liasses_fiscales/#{year}")
imprimes = %w[
2059F
2059G
]
@skelz0r
skelz0r / response.json
Created October 27, 2022 15:02
API Entreprise => /api/v2/privileges
{
"privileges": [
"certificat_rge_ademe",
"msa_cotisations",
"entreprises",
"extraits_rcs",
"certificat_opqibi",
"associations",
"etablissements",
"fntp_carte_pro",
openapi: 3.0.0
info:
description: "API Entreprise"
version: "v2"
title: "API Entreprise"
servers:
- url: "https://entreprise.api.gouv.fr"
description: "Environnement de production"
tags:
- name: &tag_general "Informations générales"
{
"options": {
"theme": "default"
},
"episode": {
"media": {"mp3": "http://assets.justjam.at/clique-x-vald/audio.mp3"},
"title": "Clique x Vald Partie I : Le vrai visage de Vald",
"coverUrl": "http://assets.justjam.at/clique-x-vald/cover.jpg"
}
}
=============================
NAME: leclere
URL: https://foursquare.com/v/leclere/55a94806498e61367ff53412
CATEGORIES: Restaurant
ATTRIBUTES:
[
{
"type": "price",
"name": "Price",
"summary": "€€",
@skelz0r
skelz0r / storage.js
Last active August 29, 2015 14:18
Devoxx 2015 : Ionic lab - Storage service
angular.module('app')
.factory('Storage', function($window){
'use strict';
var localStorageFallback = {};
var service = {
get: get,
set: set
};
@skelz0r
skelz0r / app.js
Created April 4, 2015 17:37
Devoxx 2015 : Ionic lab - Exo 2
angular.module('app', ['ionic', 'firebase'])
.config(function($stateProvider, $urlRouterProvider){
$stateProvider
.state('app', {
url: '/app',
templateUrl: 'views/app.html',
controller: 'AppCtrl'
});
$urlRouterProvider.otherwise('/app');