Skip to content

Commit

Permalink
Cleanup startpage
Browse files Browse the repository at this point in the history
  • Loading branch information
aschaeffer committed Apr 16, 2024
1 parent a41c967 commit 3848ba5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 35 deletions.
24 changes: 0 additions & 24 deletions docs/01-index.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,27 +19,3 @@ status: alpha
</p>
</article>

<img src="{{ path '/logo/full/reactive-graph-full-mexican-pink.svg' }}" style="height: 240px;" alt="Reactive Graph">


This is your index page. You can edit its contents at `docs/01-index.md`

## Card component

The card component can be included within other components like this:

```
\{{> @card }}
```

This template for this component looks like this:

```
{{view '@card'}}
```

and it therefore expects a set of data to render it that is in the following format:

```
{{context '@card'}}
```
22 changes: 11 additions & 11 deletions fractal.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,19 +60,19 @@ fractal.docs.set('statuses', {
}
});
fractal.docs.set('default.status', 'alpha');
const hbs = require('@frctl/handlebars')({
helpers: {
componentList: function () {
let ret = "<ul>";
const options = Array.from(arguments).pop();
for (let component of fractal.components.flatten()) {
ret = ret + "<li>" + options.fn(component.toJSON()) + "</li>";
}
return ret + "</ul>";
}
const handlebars = require('@frctl/handlebars')({
helpers: {
componentList: function () {
let ret = "<ul>";
const options = Array.from(arguments).pop();
for (let component of fractal.components.flatten()) {
ret = ret + "<li>" + options.fn(component.toJSON()) + "</li>";
}
return ret + "</ul>";
}
}
});
fractal.docs.engine(hbs);
fractal.docs.engine(handlebars);

fractal.web.set('static.path', path.join(__dirname, 'public'));
fractal.web.set('builder.dest', path.join(__dirname, 'build'));
Expand Down

0 comments on commit 3848ba5

Please sign in to comment.