Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mdgriffith/stylish-elephants
This project has matured and been released! Go here ->
https://github.com/mdgriffith/stylish-elephants
Last synced: about 2 months ago
JSON representation
This project has matured and been released! Go here ->
- Host: GitHub
- URL: https://github.com/mdgriffith/stylish-elephants
- Owner: mdgriffith
- License: bsd-3-clause
- Created: 2017-08-22T11:52:03.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-08-30T15:44:37.000Z (over 6 years ago)
- Last Synced: 2024-10-13T20:09:18.071Z (2 months ago)
- Language: Elm
- Homepage: https://github.com/mdgriffith/elm-ui
- Size: 604 KB
- Stars: 44
- Watchers: 9
- Forks: 8
- Open Issues: 46
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGES-FROM-STYLE-ELEMENTS.md
- License: LICENSE
Awesome Lists containing this project
README
# A New Language for Layout and Interface
CSS and HTML are actually quite difficult to use when you're trying to do the layout and styling of a web page.
This library is a complete alternative to HTML and CSS. Basically you can just write your app using this library and (mostly) never have to think about HTML and CSS again.
The high level goal of this library is to be a **design toolkit** that draws inspiration from the domains of design, layout, and typography, as opposed to drawing from the ideas as implemented in CSS and HTML.
This means:
* Writing and designing your layout and `view` should be as **simple and as fun** as possible.
* Many layout errors (like you'd run into using CSS) **are just not possible to write** in the first place!
* Everything should just **run fast.**
* **Layout and style are explicit and easy to modify.** CSS and HTML as tools for a layout language are hard to modify because there's no central place that represents your layout. You're generally forced to bounce back and forth between multiple definitions in multiple files in order to adjust layout, even though it's probably the most common thing you'll do.```elm
import Color exposing (blue, darkBlue)
import Element exposing (Element, el, text, row, alignRight)
import Element.Background as Background
import Element.Border as Bordermain =
Element.layout []
myElementmyRowOfStuff =
row [ width fill ]
[ myElement
, myElement
, el [ alignRight ] myElement
]myElement : Element msg
myElement =
el
[ Background.color blue
, Border.color darkBlue
]
(text "You've made a stylish element!")
```The work here started as a major rewrite of the [Style Elements](https://github.com/mdgriffith/style-elements).
Though, it will be released under a different name shortly.