Logo di Configuration

Configuration

OrganizzazionePopolare
live-codes
configuration

Configure playground behavior through Config object, query parameters, EmbedOptions, editor settings, processors, external resources, and custom settings. Load this skill when setting up project content, configuring CSS processors, or customizing display.

Panoramica

Autorelive-codes
Repositorylivecodes
Nome della skillconfiguration
Stelle
1.5K
Fork
271
File inclusi
Solo istruzioni
LicenzaMIT
Link
  • Istruzioni in Markdown

    Un file SKILL.md che il modello carica quando serve, consumando token solo quando una richiesta è effettivamente pertinente.

  • Funziona con qualsiasi LLM

    Le skill IA sono in semplice Markdown, non in codice specifico di un fornitore, quindi funzionano con GPT, Claude, Gemini, Grok o un modello locale.

  • Tutto nelle istruzioni

    Tutto ciò che serve al modello è nelle istruzioni: nessun file aggiuntivo da sincronizzare.

  • Open source

    Pubblicata da live-codes su GitHub. Leggi i sorgenti prima di installarla.

Installazione

Installa la skill IA Configuration in TypingMind per usarla con qualsiasi LLM, oppure copiala in un altro agente in grado di leggere SKILL.md.

1

Installa in TypingMind

TypingMind installa una skill direttamente dalla sua cartella GitHub: legge SKILL.md, raccoglie i file delle risorse e salva il risultato in locale.

  1. Apri l'app e vai su Plugin → Skill.
  2. Scegli "Installa da GitHub".
  3. Incolla l'URL della cartella della skill riportato qui sotto e conferma.
    https://github.com/live-codes/livecodes/tree/develop/.agents/skills/livecodes/configuration
  4. Attiva la skill in ogni chat in cui vuoi averla a disposizione.
Plugin → Skill → Nuova skill → Da URL GitHub, poi incolla l'URL della cartella e premi Continua.
2

Installa in un altro agente

Qualsiasi agente che legge il formato Agent Skills può usare questa skill: copia la cartella nella cartella delle skill di quell'agente.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/live-codes/livecodes.git /tmp/livecodes
mkdir -p .claude/skills
cp -r /tmp/livecodes/.agents/skills/livecodes/configuration .claude/skills/configuration
Dopo la copia, riavvia Claude Code per caricare la nuova skill.

Usala in TypingMind

Attiva Configuration in qualsiasi chat di TypingMind e al resto pensa il modello. Il nome e la descrizione della skill sono nel prompt di sistema e, non appena arriva una richiesta pertinente, il modello carica da solo le istruzioni complete: non devi mai richiamarla manualmente e non consuma token finché non viene effettivamente usata.

Il modello carica automaticamente Configuration non appena riceve una richiesta pertinente.

Funziona con qualsiasi modello IA

Le skill IA sono semplici istruzioni in Markdown, non codice specifico di un fornitore, quindi Configuration non è vincolata al modello per cui è stata scritta. Installala una sola volta in TypingMind e usala con GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama o un modello locale che esegui tu, sempre con le tue chiavi API.

  • Caricata solo quando serve

    Il prompt di sistema contiene solo il nome e la descrizione. Le istruzioni vengono recuperate alla prima richiesta pertinente, quindi una skill inutilizzata non costa nulla.

  • Cambia modello durante la chat

    Poiché la skill è composta da istruzioni e non da codice, continua a funzionare anche se cambi modello: il nuovo modello legge lo stesso file SKILL.md.

Istruzioni della skill

Questo è il contenuto di SKILL.md che il modello carica. Leggilo prima dell'installazione: una skill è un insieme di istruzioni che il tuo modello seguirà.

LiveCodes — Configure Playground

LiveCodes uses configuration objects to define project content and behavior. Config can be passed to createPlayground or set via URL parameters.

Setup

javascript
import { createPlayground } from 'livecodes';

// Full config object
createPlayground('#container', {
  config: {
    title: 'My Project',
    markup: { language: 'html', content: '<h1>Hello</h1>' },
    style: { language: 'css', content: 'h1 { color: blue; }' },
    script: { language: 'javascript', content: 'console.log("hi")' },
    activeEditor: 'script',
  },
});

// Query params (simpler syntax)
createPlayground('#container', {
  params: {
    html: '<h1>Hello</h1>',
    css: 'h1 { color: blue; }',
    js: 'console.log("hi")',
    console: 'open',
  },
});

Core Patterns

Configure each editor

javascript
const config = {
  markup: {
    language: 'markdown',
    content: '# Title\n\nParagraph',
    contentUrl: 'https://example.com/content.md', // Alternative to content
  },
  style: {
    language: 'scss',
    content: '$color: blue; h1 { color: $color; }',
  },
  script: {
    language: 'typescript',
    content: 'const x: number = 1;',
    hiddenContent: 'export function helper() {}', // Hidden but evaluated
  },
};

Enable CSS processors

javascript
const config = {
  style: { language: 'css', content: '...' },
  processors: ['tailwindcss', 'autoprefixer'], // Processors run in order
};

Add external resources

javascript
const config = {
  stylesheets: ['https://cdn.jsdelivr.net/npm/tailwindcss@3/dist/tailwind.min.css'],
  scripts: ['https://cdn.jsdelivr.net/npm/lodash@4/lodash.min.js'],
};

Configure tests

javascript
const config = {
  tests: {
    language: 'typescript',
    content: `
      import { sum } from './script';
      test('sums numbers', () => {
        expect(sum(1, 2)).toBe(3);
      });
    `,
  },
};

Set display mode

javascript
const config = {
  mode: 'simple', // 'full' | 'focus' | 'simple' | 'lite' | 'editor' | 'codeblock' | 'result'
  view: 'result', // 'split' | 'editor' | 'result'
  readonly: true, // Read-only mode
};

Configure editor settings

javascript
const config = {
  editor: 'monaco', // 'monaco' | 'codemirror' | 'codejar' | 'auto'
  theme: 'dark', // 'light' | 'dark'
  editorTheme: 'vs-dark', // See themes in docs
  fontFamily: 'Fira Code',
  fontSize: 14,
  useTabs: false,
  tabSize: 2,
  lineNumbers: true,
  wordWrap: false,
  emmet: true,
  editorMode: 'vim', // 'vim' | 'emacs' | undefined
};

Add custom imports

javascript
const config = {
  imports: {
    'my-lib': 'https://my-cdn.com/lib.js',
    'my-lib/submodule': 'https://my-cdn.com/sub.js',
  },
};

Use URL query parameters

URL: https://livecodes.io/?js=console.log("Hello")&console=open&theme=light

javascript
// Equivalent in createPlayground
createPlayground('#container', {
  params: {
    js: 'console.log("Hello")',
    console: 'open',
    theme: 'light',
  },
});

Hidden content for embedded playgrounds

javascript
const config = {
  script: {
    language: 'javascript',
    content: 'export function myFunc() { return 42; }',
    hiddenContent: '// Hidden helper\nfunction helper() { return 1; }',
  },
  tests: {
    language: 'javascript',
    content: "import { myFunc } from './script';\ntest('works', () => expect(myFunc()).toBe(42))",
  },
};

Common Mistakes

HIGH Confusing Config with EmbedOptions

Wrong:

javascript
createPlayground('#container', {
  config: {
    appUrl: 'https://my-server.com', // Wrong: appUrl belongs in EmbedOptions
    template: 'react', // Wrong: template belongs in EmbedOptions
  },
});

Correct:

javascript
createPlayground('#container', {
  // EmbedOptions (SDK-level settings)
  appUrl: 'https://my-server.com',
  template: 'react',
  loading: 'lazy',
  headless: false,

  // Config (Project content)
  config: {
    title: 'My Project',
    markup: { language: 'html', content: '<h1>Hello</h1>' },
    style: { language: 'css', content: '...' },
    script: { language: 'javascript', content: '...' },
  },
});

EmbedOptions controls how the playground is embedded (appUrl, template, loading, headless). Config controls the project content (languages, code, processors).

Source: docs/docs/sdk/js-ts.mdx — EmbedOptions section

MEDIUM Params overriding config unexpectedly

Wrong:

javascript
createPlayground('#container', {
  config: {
    markup: { language: 'html', content: '<h1>A</h1>' },
  },
  params: {
    html: '<h1>B</h1>', // This overrides config.markup!
  },
});

Correct:

javascript
// Use one source or understand precedence:
// params > config > import > template

createPlayground('#container', {
  params: {
    html: '<h1>B</h1>',
  },
  // No config needed for simple cases
});

// Or use config only
createPlayground('#container', {
  config: {
    markup: { language: 'html', content: '<h1>A</h1>' },
  },
});

When both config and params are provided, params takes precedence. Use one or the other for clarity.

Source: docs/docs/sdk/js-ts.mdx — Multiple Sources section

MEDIUM Using incorrect language name

Wrong:

javascript
const config = {
  script: { language: 'react.js', content: '...' }, // Invalid
};

Correct:

javascript
// Use language name, extension, or alias
const config = {
  script: { language: 'react', content: '...' }, // Language name
  // or
  script: { language: 'jsx', content: '...' }, // Extension
  // or
  script: { language: 'react-jsx', content: '...' }, // Alias
};

Language names must match supported values. See languages reference for all options.

Source: src/sdk/models.ts — Language type

Config Reference

Project Content

PropertyTypeDefaultDescription
titlestring"Untitled Project"Project title, used as result page title
descriptionstring""Project description, used in search
headstring"<meta charset...>"Custom content for <head> element
htmlAttrsstring | object'lang="en" class=""'Attributes for <html> element
tagsstring[][]Project tags for filtering/search
activeEditor"markup" | "style" | "script""markup"Which editor is visible
languagesLanguage[]all languagesEnabled languages in editor dropdown

Editor Content (markup, style, script, tests)

Each editor config object supports:

PropertyTypeDefaultDescription
languageLanguage(varies by editor)Language name, extension, or alias
contentstring""Initial code content
contentUrlstring—URL to load content from
hiddenContentstring—Hidden code (evaluated but not visible)
hiddenContentUrlstring—URL to load hidden content
foldedLinesArray<{from, to}>—Lines to fold on load
titlestring—Override editor title
hideTitleboolean—Hide editor title
ordernumber0Editor order in UI
selectorstring—CSS selector for DOM import
position{lineNumber, column?}—Initial cursor position

External Resources

PropertyTypeDefaultDescription
stylesheetsstring[][]URLs for external CSS
scriptsstring[][]URLs for external JS
cssPreset"" | "normalize.css" | "reset-css"""CSS preset to apply
processorsProcessor[][]CSS processors (tailwindcss, autoprefixer, etc.)

Module Resolution

PropertyTypeDefaultDescription
importsRecord<string, string>{}Custom import map for module resolution
typesRecord<string, string | object>{}Custom TypeScript type declarations

App Settings

PropertyTypeDefaultDescription
readonlybooleanfalseRead-only mode
allowLangChangebooleantrueAllow changing editor language
view"split" | "editor" | "result""split"Default view
mode"full" | "focus" | "simple" | "lite" | "editor" | "codeblock" | "result""full"Display mode
toolsobject{enabled: "all", active: "", status: ""}Tools pane config
zoom1 | 0.5 | 0.251Result page zoom level

User Settings

PropertyTypeDefaultDescription
autoupdatebooleantrueAuto-run result on code change
autosavebooleanfalseAuto-save on code change
autotestbooleanfalseAuto-run tests on code change
delaynumber1500Delay before autoupdate/autosave (ms)
formatOnsavebooleanfalseFormat code on save
layout"horizontal" | "vertical" | "responsive""responsive"Editor layout
theme"light" | "dark""dark"App theme
themeColorstring"hsl(214, 40%, 50%)"App theme color
editorThemestring | string[]—Editor themes (see docs)
appLanguagestring—UI language code (e.g., "ar", "zh-CN")
recoverUnsavedbooleantrueEnable recovery of unsaved project
welcomebooleantrueShow welcome screen
showSpacingbooleanfalseShow element spacing in result

Editor Settings

PropertyTypeDefaultDescription
editor"monaco" | "codemirror" | "codejar" | "auto"—Code editor to use
fontFamilystring—Editor font family
fontSizenumber14 (full) / 12 (embed)Editor font size
useTabsbooleanfalseUse tabs instead of spaces
tabSizenumber2Spaces per indent level
lineNumbersboolean | "relative"trueShow line numbers
wordWrapbooleanfalseEnable word wrap
closeBracketsbooleantrueAuto-close brackets/quotes
foldRegionsbooleanfalseFold #region blocks on load
minimapbooleanfalseShow minimap (Monaco)
emmetbooleantrueEnable Emmet
editorMode"vim" | "emacs"—Editor key bindings
semicolonsbooleantrueUse semicolons in formatting
singleQuotebooleantrueUse single quotes in formatting
trailingCommabooleantrueUse trailing commas in formatting

EmbedOptions Reference

PropertyTypeDefaultDescription
appUrlstring"https://livecodes.io/"URL to self-hosted LiveCodes
configConfig | string{}Project config or URL to config JSON
templatestring—Starter template name
importstring—URL to import code from
paramsobject{}URL query parameters
loading"eager" | "lazy" | "click""lazy"When to load playground
headlessbooleanfalseRun without UI

Query Parameters

Many config options can be set via URL parameters:

https://livecodes.io/?template=react&theme=light&console=open
ParamConfig Equivalent
templateEmbedOptions.template
xEmbedOptions.import
filesFiles to import (comma-separated)
rawImport URL as raw language
activeactiveEditor
modemode
themetheme
consoletools.status
no-defaultsSkip default template

Boolean params: ?lite, ?autoupdate=false Array params: ?processors=tailwindcss,autoprefixer Custom settings: ?customSettings.template.prerender=false

Domande frequenti

Cosa fa la skill IA Configuration?

Configure playground behavior through Config object, query parameters, EmbedOptions, editor settings, processors, external resources, and custom settings. Load this skill when setting up project content, configuring CSS processors, or customizing display.

Perché usare Configuration su TypingMind?

Perché la installi una volta e la usi con qualsiasi modello. Configuration è scritta in semplice Markdown anziché in codice specifico di un fornitore, quindi la stessa skill funziona con GPT-5, Claude, Gemini, Grok o un modello locale, e puoi cambiare modello durante la chat senza che smetta di funzionare. TypingMind usa le tue chiavi API, quindi paghi direttamente i fornitori anziché un abbonamento per posto utente, e le tue skill e chat restano nel tuo spazio di archiviazione.

Come installo Configuration in TypingMind?

Apri Plugin → Skill → Installa da GitHub in TypingMind e incolla https://github.com/live-codes/livecodes/tree/develop/.agents/skills/livecodes/configuration. TypingMind legge il file SKILL.md e installa la skill, che puoi abilitare per ogni singola chat.

Quali modelli IA possono usare Configuration?

Qualsiasi modello che colleghi in TypingMind. Le skill IA sono semplici istruzioni in Markdown anziché codice specifico di un fornitore, quindi GPT, Claude, Gemini, Grok e i modelli locali possono tutti caricare questa skill quando una richiesta corrisponde al suo scopo.

Quanti modelli IA posso usare con Configuration?

Quanti ne vuoi. Se un modello supporta le skill, puoi usarlo con Configuration: GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama e molti altri, tutti su TypingMind con le tue chiavi API.

La skill IA Configuration è gratuita?

Sì. È pubblicata su GitHub da live-codes con licenza MIT. Paghi solo il tuo fornitore IA per i token che usi.

Cosa sono le skill IA?

Una skill IA è un pacchetto di istruzioni riutilizzabili che insegna a un modello IA come svolgere un'attività specifica. Segue il formato aperto Agent Skills: un file SKILL.md con un nome e una descrizione, più eventuali script, modelli o file di riferimento di cui il modello potrebbe aver bisogno. Il modello legge le istruzioni solo quando la tua richiesta corrisponde alla skill, quindi una skill installata non comporta costi finché non viene usata.

In cosa si differenziano le skill IA dai plugin o dai server MCP?

Un plugin o un server MCP fornisce a un modello nuovi strumenti da richiamare: codice che viene eseguito da qualche parte e restituisce un risultato. Una skill IA, invece, fornisce al modello conoscenze e procedure: come affrontare un'attività, quali passaggi seguire e quali caratteristiche deve avere un buon output. Le skill sono semplici istruzioni in Markdown, quindi non richiedono server, chiavi API né ambienti di esecuzione e funzionano con qualsiasi modello.

Vedi tutti

Crea subito la tua area di lavoro IA

Iscriviti alla nostra newsletter per ricevere aggiornamenti sulle nuove funzionalità e sulle prossime iniziative a premi 👇