Fractal: 1.1 beta release - ready for testing

Created on 16 Dec 2016  路  9Comments  路  Source: frctl/fractal

There is now a Fractal 1.1 beta release ready for testing. It includes a number of bugfixes and a few minor feature additions. See below for a full list of changes.

In addition there is also a 1.1 beta version of Mandelbrot and a 1.2 beta of the Handlebars adapter available. If you _have not_ customised either of these you should get the new versions automatically when you install the 1.1 Fractal beta. If you _have_ installed these separately you will need to update the versions you are using in your project to get the beta releases.

Installing

Install the global CLI helper (the new version can still run projects using an older local version):

npm i -g @frctl/fractal@next

To update your project version (run the command from within your project repository):

npm i @frctl/fractal@next  --save

You can install the beta releases of Mandebrot and the Handlebars adapter in you project using the following commands:

npm i @frctl/mandelbrot@next  --save
npm i @frctl/handlebars@next  --save

Notes/main areas for testing

  • The static site 'builder' has seen some pretty large refactoring, so please check that this isn't causing any issues.
  • Component/collection preview templates - it is now possible to define a file named preview.hbs (or preview.njk etc) _within_ your component folder to use as the preview file for your component, instead of specifying another component to use as the preview in the component's configuration. You can also add a preview.hbs file within a collection (similar to a collection config file) and have it be used by all children of that collection, unless otherwise overridden. This should not clash with any existing use of component-based preview templates, but any feedback would be appreciated.
  • Short config file names are now supported - so you now no longer need to use button.config.yml but can use just config.yml instead for compound components and collections. One less thing to rename if you move things around. But does this clash with real-world naming conventions in any projects?

Changes

  • [NEW] Add support for component and collection preview templates
  • [NEW] Add support for 'short' non-component-name-prefixed config files for collections and compound components
  • [NEW] Provide meta component/docs config namespace for arbitrary user-defined metadata (#89)
  • [NEW] BrowserSync config option watchOptions.ignored can now be used to prevent ignored files from causing a UI reload (#134)
  • [NEW] Web config option builder.static.ignored can now be used to prevent ignored files in the static directories from being copied when building. (#120)
  • [NEW] Context data is now resolved when the data tree is rebuilt to allow synchronous retrieval via new entity.getContext() method.
  • [FIX] Prevent arrays being merged during context data inheritance (#123)
  • [FIX] Default variant view template issue (#67)
  • [FIX] Patch issue with commands not exiting in latest version of Vorpal
  • [OTHER] Refactor Builder class to better match Server class structure.
help-wanted

All 9 comments

Hi! I get an extrange beaviour with variations. Fractal render the component with the last variant in the array variants[]

I'm using nunjucks adapter 1.0.2 I think may be the problem..

Thanks!

@FrancisVega thanks - I'll look into it. That version of the Nunjucks adapter _should_ work with it so I'll dig into it and see what is going on!

There also seems to be an issue with the watch behaviour and config file changes not being picked up on which I'm looking into.

I鈥檓 also wondering if the current nunchucks adapter is causing issues with the beta. On testing it with http://bits.24ways.org, I鈥檓 seeing the following error when viewing /components/detail/article-template and similar templates:

  • Template render error: (unknown path) TypeError: Cannot create property '_env' on string '@summary'

I鈥檝e got quite a complex nested structure, which makes it harder to single out the specific issue, yet this setup worked with the previous version.

(There were also a few other errors, but looking at those components again they have since resolved themselves!)

I've just released v1.1-beta.4 which addresses the issue people have been seeing where Fractal was failing to re-parse the filesystem after changes had been made.

@paulrobertlloyd just FYI I've fixed the issue with Nunjucks templates in this beta. Double checked using your bits.24ways repo and it seems to be working nicely now.

Right, releasing as v1.1.0 this (and closing this issue) shortly - all known issues have been resolved.

Yup, all working nicely now. Thanks!

@allmarkedup
I had one more issue, my collection config files had their name like follows:
collection/_collection.config.yml
after update to 1.1.0 they stopped working, the solution was to change their name to one of:

  • collection/collection.config.yml
  • collection/config.yml

collection/_config.yml dosen't work too.

So the hidden file underscore-marker no longer passes in 1.1.0 for config files. It was a nice thing, because the collection config file was always on top/bottom of the file list, easy to find.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

siiron picture siiron  路  7Comments

kjugi picture kjugi  路  3Comments

alexrussell picture alexrussell  路  7Comments

julmot picture julmot  路  3Comments

weenzeel picture weenzeel  路  6Comments