From 2952077c87a6121d14f3171ba7f9b493284f2af9 Mon Sep 17 00:00:00 2001 From: Andros Fenollosa Date: Sun, 5 Jul 2020 10:44:00 +0200 Subject: [PATCH] Update README.md --- README.md | 57 ++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 56 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index fb31911..055644b 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # FFNM (Front-End for the next master) -Simple plugin to avoid writing Javascript in trivial tasks. +Simple utility to avoid writing Javascript when working with classes. ## Documentation @@ -9,6 +9,60 @@ Simple plugin to avoid writing Javascript in trivial tasks. --- +## English + +### Install + +Add to your `` the following tag. + +```html + +``` + +### Examples + +#### Click + +##### Add the class `show` to the `#nav` selector when the button is pressed. + +```html + +``` + +##### Remove the `show` class from the `#nav` selector when the button is pressed. + +```html + +``` + +##### Switch the `show` class to the `#nav` selector when the button is pressed. + +```html + +``` + +#### Classes without events + +##### Add the class `show` to the `#nav` selector + +```javascript +class:add('show', '#nav') +``` + +##### Remove the `show` class from the `#nav` selector + +```javascript +class:remove('show', '#nav') +``` + +##### Switch the class `show` to the `#nav` selector + +```javascript +class:toggle('show', '#nav') +``` + +--- + ## Spanish/EspaƱol ### Instalar @@ -60,6 +114,7 @@ class:remove('show', '#menu') ```javascript class:toggle('show', '#menu') ``` +--- ## Development