A package that can be used to render CSS easing functions. One can use the
Easing type to specify how the "speed" of a certain animation should be
handled in time.
This package can be used in other items, such as objects that are then converted to JSON to make it more safe, since it narrows the amount of possible css strings to valid CSS easing functions.
The package documentation can be found on the GitHub pages.
There are two types of CSS easings:
steps(n, jump-term)with n the number of steps, and jump-term the type of jump; and
quadratic-bezier(x1, y1, x2, y2)that works with a quaratic Bezier curve. Here both
x2need to between 0 and 1.
The type that we use for easings in this package is
There are four types of jumps:
end are aliasses for
respectively. The type we use in this package for these is
Besides that, CSS has some aliasses for common easing types like
PostCSS defines extra aliases like:
These are also included as patterns in this project. When these are rendered, for example as a JSON string, it will use the CSS equivalent.
Easing type are members of the
ToMarkup, the CSS counterparts are just written to the markup stream,
and thus not wrapped in a string literal. Since the possible easings do not
contain any characters that need to be escaped, there is no problem with
ToJSON instances, the values are wrapped in a JSON
Arbitrary css easings
One can generate arbitrary
JumpTerms. It is however not advisable to
use this for anything other than for validation purposes (like with
css-easings is not safe Haskell
There are not extensions that are used that make the library itself
unsafe, but it makes use of
blaze-markup, etc. and the packages are
not safe. Hence this package is not safe Haskell.
You can contribute by making a pull request on the GitHub repository.
You can contact the package maintainer by sending a mail to
This package is dedicated to Nordin Allaert (2001-2020), the son of a colleague. His life went in an
ease-in manner, but was taken too soon.