fountain-js
Advanced tools
Changelog
[1.2.4] - 2023-11-13
:
) within the value portion of the tile page key-value pair would be truncated after the colon.^5.0
to avoid breaking changes with @types/node
.Changelog
[1.2.3] - 2023-11-13
Revision(s)
is now a recognized title page keyword.end_of_lines
rule not splitting properly when new lines have horizontal whitespace.EXT. BRICK'S GARAGE - DAY\nTrailing action...
, is consumed and lost by the lexer. Now both token and additional lines fall to action instead since these specific tokens require newlines after them to be valid.end_of_lines
is now blank_lines
.Scanner
class is now Lexer
and is importable.Lexer
and InlineLexer
classes are now static.tokenize
method in Lexer
class now returns a tuple composed title page tokens and script tokens for quicker access, no need to filter by is_title
anymore.
Fountain
class property tokens
still presents all tokens in a single array as before (no changes). One can still filter by is_title
as desired as previously.Changelog
[1.2.2] - 2023-10-28
Title
, Credit
, Author/s
, Source
, Notes
, Draft date
, Date
, Contact
, or Copyright
.Changelog
[1.2.1] - 2023-10-28
InlineLexer
.Changelog
[1.2.0] - 2023-10-27
<p>undefined</p>
.Changelog
[1.1.4] - 2023-10-01
@ # ! $ \ / ~ ` + = . > <
are all escapable in addition to *
and _
. Additionally, all escapes are also respected when used to break the tokens' intended function.< > & "
now escape to their HTML-safe variants.Record<T, U>
for the lexers. These types have been included for import and manipulation as desired.Changelog
[1.1.3] - 2023-09-24
I./E.
is now valid where originally it wasn't.*(ah, wonderful)*
as well as inside.Changelog
[1.1.2] - 2023-09-17
this.tokens
is created in order to perserve token text from being mutated by the inline lexer within to_html
. The text within tokens will no longer contain HTML.InlineLexer
class, a modified version of said class, or alternatively you can use Fountain.to_html()
seperately if desired.getTokens
parameter on parse
or through the tokens
property on the Fountain
class itself.regex
object and lexer classes like Lexer
and InlineLexer
can now be imported in order extend for additional token manipulation, particularly when it comes to lexing token text.Changelog
[1.1.1] - 2023-09-13
#
, $
, %
, etc., now work in character names and are valid.23
do not work but numbers in character names work regardless of order e.g. R2D2
or 11A
.123
, if desired.Changelog
[1.1.0] - 2023-06-26
INT./EXT
and INT/EXT
in scene headings are now parsable.