Giter VIP home page Giter VIP logo

quaint-quaint's Introduction

quaint-quaint

Interactive Quaint textboxes in Quaint documents.

quaint-quaint will automatically start a Quaint interpreter listening to changes to one or more textareas and running in a separate Worker. For each marked textarea, an output div is created and will be updated automatically with the result of the compilation of the current contents.

quaint-quaint does not define a stylesheet, but it should not be very complicated to style. See below for the generated HTML.

Install

quaint --setup quaint

Sample use

Edit this:

&&
  Quaint is __awesome!
  # One
  # Two
  # Three

Ten-lines-high uninitialized editor:

10 &&

The generated code will look like this:

<div class="quaint-interactive">
  <div class="quaint-input">
    <textarea rows="10">
      Quaint is __awesome
    </textarea>
  </div>
  <div class="quaint-output">
    Quaint is <strong>awesome</strong>
  </div>
</div>

quaint-quaint does not contribute any stylesheet, so you will need to style the above yourself.

Rules

nrows && body

Creates an interactive Quaint editor initialized with body, and with nrows rows of text. If nrows is unspecified, then the number of lines in body will be used (line wrapping is not taken into account).

Options

preCompute

(default: true)

If true, Quaint will pre-compute the result of every interactive editor. That's kind of slow, so you can flip that off if needed, while developing.

quaint-quaint's People

Contributors

breuleux avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.