Permalink
Switch branches/tags
Nothing to show
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
82 lines (79 sloc) 3.42 KB
extends ../docs-base
//- block doc
h1 Prologue
blockquote hi?
p.
Hello! Thank you for checking out the docs of fig.js - the JavaScript UI
framework which is going to solve all of your life's problems!
blockquote another crappy js framework, yea right go on
p.
Hey there, no need to be rude! You didn't even have the chance to
hear about its beautiful integrated pug templates, well separated
component definitions, clean and simple to understand API, verbose debug
messages, the ability to interface with other libraries with just one
simple stateme...
blockquote wait a minute, did you mention pug templates? i like pug templates
p.
Yes! This was actually the main goal of this project - to bring pug.js
into the amazing world of dynamic client-side views, updated with models
which are manipulated by controllers. An MVC pattern, you could call it!
blockquote
| isn't pug like a bulky server-side library though? how come is fig
| just 5kB in size?
p.
Great question! In order for us to use pug without exploding the
distribution size, some trade offs had to have been made. To build
an app with fig you will need to use some external tooling, but that's
all explained in the next section.
blockquote
| ok but is this whole thing like for real? why are you putting the
| word "experimental" everywhere like some undecided freak
p.
Well, both yes and no. Fig is not meant to be the "next big thing",
the "react killer", or any of that stuff. It's an attempt to learn
the insides of the modern JavaScript ecosystem, an exploration of
my personal problem solving skillz and what could be built combining
the two together.
#[b I don't expect anyone to use fig seriously at this stage of development though.]
blockquote who are you anyways?
p.
Just a random guy from the internet creating random open-source tools,
you can checkout my website #[a(href='https://nikerino.com') here] if
you want to. Let's move on to the next section!
block doc
h1 Prologue
p.
Hello! Thank you for checking out the docs of fig.js - the JavaScript UI
framework which is going to solve all of your life's problems!
h2 What?
p.
Fig.js (henceforth referred to as fig) is a component-based,
experimental MVC framework powered by
#[a(href='https://pugjs.org') pug templates] and a minimalistic API.
Also includes a verbose logger and a nice interface to interact with
other DOM libraries.
h2 Why?
p.
The main goal of this project was to provide an abstraction layer to
bring pug.js into the world of dynamic client-side rendered content,
with a sweet side effect of gathering more knowledge throughout
the process.
h2 How?
p.
In order to reduce the potential weight of the library, pug is used
server-side to compile the markup into pure JavaScript functions that
spit out HTML, which are sent to the client. Unfortunately, that doesn't
make fig the most plug-and-play framework out there, although we believe
it is still a fair trade-off between its size and its simplicity.
h2 Compatibility?
p.
Due to time constraints, fig is targeted towards only the most modern
of browsers. It is not guaranteed to work properly on older browsers,
or even at all.
h2 Who?
p.
I'm just a random guy from the internet creating more random open-source
tools and libraries, you can
#[a(href='https://nikerino.com') checkout my website] for more
incredibly exciting information. Anyways, let's move on to the
next section!