NullVoxPopuli / limber

Glimdown playground for documentation, demos, etc

Home Page:https://limber.glimdown.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add support for *.gjs in live code blocks

NullVoxPopuli opened this issue · comments

Example:

code-fence tag: gjs live

// ```gjs live
const foo = 'hi';

<template>
  woosh {{foo}}
</template>
'''
// ```gjs live
import Component from '@glimmer/component';

class Foo extends Component {
  @tracked num = 2;

  <template>
    {{this.num}}
  </template>
}

in both cases, the live tag creates a component named after guidFor(the content in the codefence) and then replaces the codefence block with an invocation to that component in the markdown

Done!