Skip to content

Commit

Permalink
@fluent/syntax 0.14.0
Browse files Browse the repository at this point in the history
  • Loading branch information
stasm committed Jul 25, 2019
1 parent 49d5d3d commit a2d9a03
Show file tree
Hide file tree
Showing 6 changed files with 24 additions and 20 deletions.
2 changes: 1 addition & 1 deletion fluent-syntax/.esdoc.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"source": "./src",
"destination": "../html/fluent-syntax",
"destination": "../html/syntax",
"plugins": [
{
"name": "esdoc-standard-plugin"
Expand Down
4 changes: 2 additions & 2 deletions fluent-syntax/.gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
fluent-syntax.js
compat.js
/index.js
/compat.js
4 changes: 4 additions & 0 deletions fluent-syntax/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## @fluent/syntax 0.14.0 (July 25, 2019)

- Rename `fluent-syntax` to `@fluent/syntax`.

## fluent-syntax 0.14.0 (July 25, 2019)

- Deprecate fluent-syntax. Plase use @fluent/syntax from now on.
Expand Down
22 changes: 11 additions & 11 deletions fluent-syntax/README.md
Original file line number Diff line number Diff line change
@@ -1,34 +1,34 @@
# fluent-syntax
# @fluent/syntax

`fluent-syntax` is a parser for Fluent translation files, FTL. Project Fluent
is a localization framework designed to unleash the expressive power of the
natural language.
`@fluent/syntax` is a parser for Fluent translation files, FTL. Project
Fluent is a localization framework designed to unleash the expressive power
of the natural language.


## Installation

`fluent-syntax` can be used both on the client-side and the server-side. You
`@fluent/syntax` can be used both on the client-side and the server-side. You
can install it from the npm registry or use it as a standalone script (as the
`FluentSyntax` global).

npm install fluent-syntax
npm install @fluent/syntax


## How to use

```javascript
import { parse, Resource } from 'fluent-syntax';
import {parse, Resource} from "@fluent/syntax";

const res = parse(`
brand-name = Foo 3000
welcome = Welcome, { $name }, to { brand-name }!
-brand-name = Foo 3000
welcome = Welcome, {$name}, to {-brand-name}!
`);

assert(res instanceof Resource);
```

The API reference is available at
http://projectfluent.org/fluent.js/fluent-syntax.
http://projectfluent.org/fluent.js/syntax.


## Compatibility
Expand All @@ -37,7 +37,7 @@ For legacy browsers, the `compat` build has been transpiled using Babel's [env
preset][]:

```javascript
import 'fluent-syntax/compat';
import "@fluent/syntax/compat";
```


Expand Down
8 changes: 4 additions & 4 deletions fluent-syntax/makefile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
PACKAGE := fluent-syntax
PACKAGE := @fluent/syntax
GLOBAL := FluentSyntax

include ../common.mk

build: $(PACKAGE).js compat.js
build: index.js compat.js

$(PACKAGE).js: $(SOURCES)
index.js: $(SOURCES)
@rollup $(CURDIR)/src/index.js \
--config $(ROOT)/bundle_config.js \
--banner "/* $(PACKAGE)@$(VERSION) */" \
Expand All @@ -24,7 +24,7 @@ compat.js: $(SOURCES)
@echo -e " $(OK) $@ built"

clean:
@rm -f $(PACKAGE).js compat.js
@rm -f index.js compat.js
@rm -rf .nyc_output coverage
@echo -e " $(OK) clean"

Expand Down
4 changes: 2 additions & 2 deletions fluent-syntax/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "fluent-syntax",
"name": "@fluent/syntax",
"description": "AST and parser for Fluent",
"version": "0.14.0",
"homepage": "http://projectfluent.org",
Expand All @@ -18,7 +18,7 @@
"directories": {
"lib": "./src"
},
"main": "./fluent-syntax.js",
"main": "./index.js",
"module": "./src/index.js",
"repository": {
"type": "git",
Expand Down

0 comments on commit a2d9a03

Please sign in to comment.