0.1.17 • Published 7 months ago

mimor v0.1.17

Weekly downloads
-
License
-
Repository
-
Last release
7 months ago

Mimor Web Component

[ Playground ]

A web component for creating flashcard by simple <question> & <answer> markup.

Usage

Install

Using CDN

<script src="https://unpkg.com/mimor"></script>

Using npm

npm install mimor
import 'mimor'

<x-mimor> Web Component

A web component call "x-mimor" will be defined:

<x-mimor
  style="height: 36rem; width: 36rem"
  src="https://mimor.xieyuheng.com/contents/example.mimor"
  theme-name="light"
></x-mimor>

Use the following Props to config the component:

type Props = {
  src: string
  text?: string
  langTag?: 'en' | 'zh'
  themeName?: 'dark' | 'light'
}

It is ok to use lisp-case naming convention in html:

<x-mimor
  src="https://..."
  text="..."
  lang-tag="en"
  theme-name="light"
></x-mimor>

Examples

[ Goto The Playground ]

<metadata theme-color="blue" />

<question>
  What it means to remember something?

  <answer>
    To remember something is to be able to recall it from memory when needed.
  </answer>
</question>

<question>
  How to remember something?

  <answer>
    One way to remember something is to recall it often.
  </answer>
</question>

<question>
  How do you use mimor to make memory a choice?

  <answer>
    By making notes in form of &lt;question&gt; and &lt;answer&gt;,
    and to recall them whenever wished,
    to help me remember them.
  </answer>
</question>

npm.io

In browser editor

You can also use this in browser editor, to edit mimors and preview mimors locally.

Currently we support Chromium-based browsers (such as Chrome and Edge).

npm.io

Development

npm install     # Install dependencies
npm run dev     # Start the dev server
npm run check   # Type check
npm run build   # Build the lib/ and dist/
npm run format  # Format the code

Contributions

To make a contribution, fork this project and create a pull request.

Please read the STYLE-GUIDE.md before you change the code.

Remember to add yourself to AUTHORS. Your line belongs to you, you can write a little introduction to yourself but not too long.

License

GPLv3

0.1.13

7 months ago

0.1.14

7 months ago

0.1.15

7 months ago

0.1.17

7 months ago

0.1.10

8 months ago

0.1.11

8 months ago

0.1.12

8 months ago

0.1.0

8 months ago

0.1.1

8 months ago

0.1.8

8 months ago

0.1.7

8 months ago

0.1.9

8 months ago

0.1.4

8 months ago

0.1.3

8 months ago

0.1.6

8 months ago

0.1.5

8 months ago

0.0.23

2 years ago

0.0.20

2 years ago

0.0.21

2 years ago

0.0.22

2 years ago

0.0.17

2 years ago

0.0.18

2 years ago

0.0.19

2 years ago

0.0.15

2 years ago

0.0.14

2 years ago

0.0.13

2 years ago

0.0.12

2 years ago

0.0.11

2 years ago

0.0.10

2 years ago

0.0.9

2 years ago

0.0.8

2 years ago

0.0.7

2 years ago

0.0.6

2 years ago

0.0.5

2 years ago

0.0.4

2 years ago

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago