• Stars
    star
    504
  • Rank 84,245 (Top 2 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created about 8 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A library for explaining things in HTML.

Expounder

Expounder is a small JS library that implements a concept I had for adaptable experience levels in educational texts. In more concrete terms, expounder allows authors of tutorials to hide their explanations if they expect readers to be familiar with a concept. The author can choose to add a link to the concept, which will appear underlined, and the reader can click on it to expand the next few sentences, paragraph or any other element that explains the concept.

This way, people familiar with a term don't need to spend a paragraph reading about it or waste time (and potentially miss other useful information) skimming ahead. You can see an example in the examples directory, on the Expounder page or on one of my posts.

Here's a demo GIF, from the Expounder page:

Usage

Expounder.js can be added to your site in two simple steps:

  1. Download and include expounder.js and expounder.css (or the minified version, for production) in your page. Alternatively, just add these two lines to your HTML:
    <script src="https://cdn.jsdelivr.net/gh/skorokithakis/expounder@master/expounder.js"></script>
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/skorokithakis/expounder@master/expounder.css" />
  2. Add data-expounderwith arbitrary IDs for span elements that will act as hooks that expand areas, and data-expounded for the areas to be expanded.

For example:

In the land of Mordor, in the fires of <span data-expounder="mount-doom">Mount
Doom</span>, the Dark Lord Sauron forged in secret, a master ring, to control
all others.

<div data-expounded="mount-doom">Mount Doom is that big-ass mountain over there
with the fires coming out of it.</div>

If you want the links to be collapsible again after they've been clicked, you can include the script with data-default-collapse="true" in the script tag (see the examples/ dir for usage), though this is discouraged for usability.

License

This library is released under the MIT license (see the LICENSE file).

Thanks

Thanks go to:

  • Stelios, who wrote the code for the entire thing.

Changelog

  • 0.0.3 -- 4/3/2016 Updated the API, added the ability to expand every element with the same data-expounded id from a single expounder link.
  • 0.0.2 -- 4/1/2016 Added contract option with data-expounder-c attribute.
  • 0.0.1 -- 3/13/2016 Initial release.

More Repositories

1

catt

Cast All The Things allows you to send videos from many, many online sources to your Chromecast.
Python
3,257
star
2

shortuuid

A generator library for concise, unambiguous and URL-safe UUIDs.
Python
1,905
star
3

django-annoying

A django application that tries to eliminate annoying things in the Django framework. ⛺
Python
917
star
4

tbvaccine

A small utility to pretty-print Python tracebacks. ⛺
Python
376
star
5

django-loginas

"Log in as user" for the Django admin.
Python
355
star
6

python-yeelight

A Python library for controlling YeeLight WiFi RGB bulbs (mirror of https://gitlab.com/stavros/python-yeelight).
Python
262
star
7

goatfish

A small, schemaless Python ORM that is backed by SQLite. ⛺
Python
233
star
8

netproxy

A Netflix/Hulu/Pandora/etc proxy in a box.
Python
230
star
9

python-fuse-sample

A sample FUSE filesystem in Python.
Python
169
star
10

django-project-template

The Django project template I use, for installation with django-admin.
Python
161
star
11

gr8w8upd8m8

Gr8W8Upd8M8 is a script to automatically read your weight from a Wii Balance Board. ⛺
Python
145
star
12

imdbapi

An API for the IMDB site. ⛺
Python
131
star
13

A6lib

An ESP8266/Arduino library for communicating with the A6 GSM module. ⛺
C++
127
star
14

jsane

A saner way to traverse JSON in Python
Python
125
star
15

encbup

Encrypted backups (without the backups)
Python
121
star
16

sysaidmin

A GPT-powered sysadmin.
Python
115
star
17

tiny-ESP8266-breakout

A very small and basic ESP8266 breakout board
110
star
18

omnisync

omnisync is a universal file synchroniser and backup program (think rsync) that supports multiple transport systems (such as plain files, sftp, s3 and virtual, currently, and support for ftp, http, et al is planned). It is designed to be fast, small, extensible, portable and bandwidth-efficient. It is available for Linux, Windows and Mac. ⛺
Python
87
star
19

iRotary

One man's quest to turn an old rotary phone into a mobile phone.
Arduino
83
star
20

django-cloudflare-push

A piece of middleware that uses Cloudflare's HTTP/2 Push to push static media to the clients. ⛺
Python
75
star
21

gweet

A message queue for the abhorrently named Internet of Things
Go
70
star
22

static-appengine-hoster

An App Engine application for hosting static sites under multiple domains in a single app.
Python
66
star
23

django-tokenauth

Django authentication backend that uses tokens sent over email.
Python
63
star
24

arduino-irrigation

A GSM-based Arduino remote controller for an irrigation system.
Arduino
62
star
25

esplights

A home automation sensor and controller based on an ESP8266.
Arduino
48
star
26

yeecli

A command-line utility for a YeeLight RGB lamp. (mirror of https://gitlab.com/stavros/yeecli)
Python
42
star
27

episode-renamer

Episode renamer is a simple python script that renames folders of TV episode video files to their proper names.
Python
41
star
28

kicad-lib

My KiCad components library.
35
star
29

Spamnesty

A service that tries to have some fun with spam (mirror of https://gitlab.com/stavros/Spamnesty/)
Python
33
star
30

captainwebhook

Captain Webhook eats webhooks and executes commands.
Python
30
star
31

spamgpt

SpamGPT, a bot that wastes spammers' damn time, like they waste mine.
Python
25
star
32

pastebinit

pastebinit is a command-line tool to send data to a "pastebin", a web site which allows its users to upload snippets of text for public viewing. ⛺
Python
25
star
33

apache-config

A script for configuring apache with Django+wsgi/fcgi+virtualenv+etc.
Python
23
star
34

ArduiRC

Remotely control IR/RF devices from a computer with Arduino.
Arduino
18
star
35

docker-fgallery

A Dockerfile for installing fgallery. ⛺
Shell
18
star
36

ez-openai

Ez API, ez life.
Python
16
star
37

landing-page

A very simple landing page app for AppEngine.
Python
15
star
38

stringphone

String phone is a secure communications protocol and library geared towards embedded devices.
Python
14
star
39

bakeit

A command-line utility for pastery, the best pastebin in the world.
Python
12
star
40

pythess-files

The code files/presentations/everything else used in the PyThess meetup
Jupyter Notebook
11
star
41

lektor-shortcodes

A shortcodes plugin for lektor
Python
11
star
42

shufflecast

A TV channel with all your favorite shows.
Python
11
star
43

photocopy

A script to archive photos off a camera to a directory.
Python
10
star
44

nxt-python

NXT-Python is a python driver/interface for the Lego Mindstorms NXT robot based on NXT_python.
Python
10
star
45

Reverend

A clone of Reverend, the naive Bayesian classifier written in Python.
Python
10
star
46

A6-ESP8266-breakout

A breakout board that includes an ESP8266 and an A6 GSM module, for easily making GSM-enabled applications (mirror)
Shell
9
star
47

Pythia

High quality & fast "true random" number generator (shuffling system)
JavaScript
9
star
48

lektor-thumbnail-generator

A thumbnail generator for Lektor content
Python
9
star
49

pastery.vim

A Vim plugin for the sweetest pastebin in the world, pastery.net.
Vim Script
9
star
50

apt-btrfs-snapshot

A fork of apt-btrfs-snapshot.
Python
8
star
51

gamelights

An RGB LED strip WiFi controller, complete with code and PCB designs.
KiCad Layout
8
star
52

mediacenter-in-a-box

A media center in a box, compatible with Harbormaster for one-line deployments.
Python
8
star
53

pylast

A clone of Amr Hassan's pylast: a python interface to last.fm (and other api-compatible websites)
Python
6
star
54

awesomeblog-club

An easily self hostable curation site for collecting blogs and links.
TypeScript
5
star
55

django-project-templates

Some Django project templates for various things.
4
star
56

requests-guard

requests-guard is a small library that allows you to impose size and time limits on your HTTP requests.
Python
4
star
57

ChatGPT-Bot

A small Python library that makes it easier to write a ChatGPT bot.
Python
4
star
58

rust-bakeit

A command-line client for pastery.net, the best pastebin in the world (official mirror of https://gitlab.com/stavros/rust-bakeit).
Rust
3
star
59

the-spam-chronicles

The Spam Chronicles, a static website where I post all the spam I got and SpamGPT auto-replied to.
Python
2
star
60

progress

A simple progress bar in Python
Python
2
star
61

blacklist-pre-commit-hook

A pre-commit hook for blacklisting certain functions
Python
2
star
62

back-scratcher

A back scratching robot!
Python
2
star
63

zulipbot

A ChatGPT Zulip bot
Python
1
star
64

iphoneconverter

A small script to convert a folder of videos into an iPhone format.
1
star
65

reddit-rage-faces

An Opera extension to put ragefaces in every subreddit.
JavaScript
1
star