Skip to content

Latest commit

 

History

History
603 lines (328 loc) · 28.6 KB

CHANGELOG.md

File metadata and controls

603 lines (328 loc) · 28.6 KB

Changelog

Unreleased

v3.10.1 (August 28, 2024)

  • Bookshop Astro Features & Fixes
    • Add support for GIF, TIFF and AVIF image imports (PR #197 — thanks @oliverlynch !)

v3.10.0 (May 20, 2024)

  • Bookshop Astro Features & Fixes
    • Adds component error boundaries to the Astro engine.
    • Adds support for client rendered components inside Bookshop components.
    • Astro Bookshop will now attempt to load build plugins from your integrations.
    • Fixes an issue where the asset URLs generated by Astro Bookshop during live editing were wrong.
    • Fixes an issue where Astro Dynamic tags would break live editing.
    • Fixes some inconsistencies in content collections between Bookshop and Astro.
    • Fixes some inconsistencies in the Image component between Bookshop and Astro.
    • Fixes an issue where component names containing dashes would break MDX auto-imports.
    • Fixes an issue where React TSX components would fail to parse.
    • Fixes an issue where scripts in Astro components would be run multiple times when live editing.
    • Fixes an issue where the Astro engine was too lenient when checking bookshop names.

v3.9.0 (December 22, 2023)

  • Adds support for the astro:content and astro:assets modules inside Bookshop components.
  • Adds support for the <slot/> component and the Astro.slots global inside Bookshop components.
  • Astro Bookshop will now use your configured Vite plugins when building components.

v3.8.2 (December 5, 2023)

  • Fixes an error in Astro Bookshop, when spreading a prop that is possibly undefined.
  • Fixes the Bookshop browser failing to load for Astro sites.
  • Astro Bookshop will now detect component folders within subfolders of the Astro src folders.

v3.8.1 (October 5, 2023)

  • Fixes an error when loading Bookshop's dependencies through CloudCannon's client editing interface

v3.8.0 (September 27, 2023)

  • Added support for extraFiles that can be passed to Bookshop's Hugo engine, allowing custom shortcodes and partials to be used

v3.7.0 (September 21, 2023)

  • Added support for Sass and CSS imports in Astro components
  • Fixed an error when bundling an Astro component with no props
  • Fixed support for React components when using Astro 3
  • Fixed support for scoped CSS when using Astro 3
  • Fixed an inconsistency in CSS class name generation
  • Fixed an issue with live rendering a component with multiple Front Matter props in Astro
  • Fixed Astro databindings for components with multiple Front Matter props with no common prefix

v3.6.5 (July 19, 2023)

  • Fixed an edge case generating structures for component names that end with the word components

v3.6.4 (July 18, 2023)

  • Fixed ENV_BOOKSHOP_LIVE flag being undefined when live editing Astro components

v3.6.3 (June 28, 2023)

  • Improved memory performance when live editing

v3.6.2 (June 8, 2023)

v3.6.1 (June 6, 2023)

  • Improved error handling for Astro Bookshop sites.
  • Fixed a bug which could cause incorrect component data-bindings for Astro sites.
  • Fixed Bookshop metadata not being correctly removed from Astro components in some cases.

v3.6.0 (June 1, 2023)

Astro Bookshop 🚀

This release introduces experimental support for Astro Bookshop sites 🙌

We're also transitioning away from the current (intimidating) reference guides in this repository, so all of the details on Astro Bookshop can be found in the new Bookshop Astro Guide on the CloudCannon documentation.

Other changes

  • Improved live editing performance for Eleventy and Jekyll sites

v3.5.1 (May 12, 2023)

  • Fixes a performance regression when live editing Hugo with many literal assignments
    • Since 3.4.0 literal assignments such as {{ $var := "string" }} caused a significant performance hit. This has now been resolved

v3.5.0 (May 10, 2023)

This release adds component error boundaries to the Hugo, Jekyll, and Eleventy live editing engines.

Now when syntax errors or unsupported SSG features are used, the individual component should render an error on the page, and the surrounding components will continue to render correctly. This only applies to the CloudCannon live editing environment, and does not impact your production website build.

v3.4.1 (March 23, 2023)

Fixed an error where nested object arrays in a component blueprint would error out.

blueprint:
  title: Hello World
  nested:
    # `nested` would be made into an array structure with a value matching the below object
    - title: "Nested Object #1"
      double_nested:
        # This would not work and `double_nested` would default to a string array
        - title: "Nested Object #2"

This release fixes this behaviour, and deeply nested object arrays will behave as expected.

v3.4.0 (March 9, 2023)

New Hugo renderer

The main aspect of this release is a new and improved Hugo renderer when live editing on CloudCannon. Alongside being more reliable, this unlocks many templating functions that were previously unavailable, such as:

  • newScratch
  • absURL
  • highlight
  • humanize

Additionally, functions that would previously cause a full error (such as resources.Get) will now return nil, and as such can be handled gracefully inside a component.

Looking forward, this release also paves the path for supporting site actions like site.GetPage in the visual editor, as well as using custom non-Bookshop Hugo partials in the visual editor.

As with all releases, your repository can be upgraded to the latest Bookshop by running:

npx @bookshop/up@latest

Other changes

  • Hugo WebAssembly files are now preloaded in CloudCannon, so loading the visual editor should be significantly faster
  • Improved data binding support for Hugo template files, and generally fixed many issues with complex templating
  • Reduced noise in the developer console when live editing Hugo Bookshop sites

v3.3.3 (December 2, 2022)

  • Added a markdownify filter to Eleventy Bookshop

v3.3.2 (November 30, 2022)

  • Fixes a v3.1.1 error when running the @bookshop/browser command for Hugo

v3.3.1 (November 29, 2022)

  • Fix nested component keys in SvelteKit websites (@NJKode — #125)
  • Stopped loading Hugo WebAssembly files from cdn.bookshop.build
    • These are instead compressed and served from the site alongside Bookshop assets
  • General repository tidyups and release automation, in preparation for a larger Hugo Bookshop release

v3.3.0 (August 03, 2022)

Features & Improvements

  • Component Initialization
    • Component blueprints referencing nested components can now initialize those components on creation with the ! operator. See Initializing Nested Components in the relevant guide.
  • SvelteKit Beta Support
    • Bookshop now supports SvelteKit, with live editing provided by the existing CloudCannon Svelte Connector.
    • See the newly created SvelteKit Guide to get started.

Fixes & Tweaks

  • Fixed some console errors when live editing in Hugo
  • Improved the initialization speed of Hugo live editing

3.1.3 (2022-06-17)

Bug Fixes

  • eleventy collection loops no longer crash (84a64c4)
    • The forloop.name feature implemented in liquidjs has now made it to Eleventy, so the Bookshop workaround has been removed. This workaround was previously causing a crash when nested inside a collection loop.

Features

  • default @bookshop/init to new component if a bookshop dir was found (12ad117)
    • Previously, running @bookshop/init would prompt you for the decision between creating a new component or a new Bookshop every time. Now, if it find a Bookshop directory it will default to the new component decision.

3.1.2 (2022-05-10)

Bug Fixes

  • set input configuration on generated structures within blueprints (ed0d6b3)
    • Previously, an array of objects within a component would not use a field configured in the _inputs block of the component. Any _ cascade fields are now set on all generated sub-structures in a component.

3.1.1 (2022-05-04)

Bug Fixes

  • move the Hugo live environment flag to site.Params (0d6b0c8)
    • Flag has been moved to site.Params.env_bookshop_live: Hugo docs

3.1.0 (2022-05-04)

Features

3.0.1 (2022-04-12)

Bug Fixes

  • add _bookshop_name keys to structures in the component browser (513cb32)

  • override nested components with preview in the component browser (7b3ab9b)

  • support adding multiple nested components in the component browser (0ad843e)

3.0.0 (2022-04-07)

Features

  • Bookshop has a new component configuration syntax. See the Bookshop 3.0 migration guide for in-depth information

    • The new configuration files allow for your inputs to be configured using CloudCannon's _inputs configuration
  • Your component blueprint can now nest other components and structures (c1dd5f2)

    • By using bookshop:<component> or bookshop:structure:<structure> in your component blueprint, you can nest the blueprint of other components, rather than having to re-specify their fields.
    • See the Jekyll, Eleventy, or Hugo guide for more examples.
  • eleventy: Site data and collections are now available to your templates while live editing (df009c4)

    • For data to be accessible, you will need to expose each data set using data_config in your CloudCannon Global Configuration file.
  • hugo: site.Data is now available to your templates while live editing (cac0fd3)

    • For data to be accessible, you will need to set data_config: true in your CloudCannon Global Configuration file.
  • hugo: Site string functions are now available to your templates while live editing (a71e1ea)

    • This encompasses the common configuration variables site.Title, site.BaseURL, and site.Copyright
  • Embedding the Component Browser is now easier across all SSGs (1226d01)

    • Using the {% bookshop_component_browser %} or {{ partial "bookshop_component_browser" }} is now all that is needed.
    • This will handle both local browsing of the component library, and building a hosted component library.
  • Bookshop will now set a CMS loading state while live editing is initializing (5b65707)

    • This is especially helpful for first loads on Hugo sites, while loading the live editing WebAssembly
  • The bookshop/init command can now create new Bookshop projects (824de51)

    • Running npx @bookshop/init --new <name> will scaffold out a new Bookshop for you
  • The new npx @bookshop/up@latest command can upgrade all Bookshop dependencies. (6ffe599)

    • This will also migrate old config files to the new syntax, and can convert between different file formats.
  • npx @bookshop/init can now generate all supported file formats (4ab5276)

  • eleventy: The url filter is now available to your templates while live editing (bd44ae0)

    • This requires that a pathPrefix is passed to eleventy-bookshop in your .eleventy.js.
  • jekyll: The relative_url filter is now available to your templates while live editing (79304cc)

  • Bookshop will now log a console error when your live editing package versions don't match the Bookshop plugin version your site was built with (798e7ed)

Bug Fixes

  • eleventy: Bookshop live editing no longer crashes when passing recursive data structures to components (98610b4)

  • jekyll/eleventy: Variables using complex filters with arguments now render correctly (d87797c)

  • jekyll/eleventy: Variable assignments that span multiple lines now render correctly (d87797c)

  • browser: The component browser now loads in safari (10eb05f)

  • hugo: Nested component paths (like sections/hero) are now correctly resolved when live editing (5fab912)

  • hugo: Ranging over a map now works correctly when live editing (46a0d51)

  • hugo: Loading a hosted Bookshop Component Library now loads the WebAssembly correctly (0d8cc82)

  • hugo: Live editing in Hugo now loads the WebAssembly from a cdn correctly (e9b9aaf)

BREAKING CHANGES

  • Bookshop config files now have a different structure. See the Bookshop 3.0 migration guide for more information.

  • eleventy/jekyll: Eleventy and Jekyll sites will need to change from the {% bookshop_browser <PORT> %} tag to the {% bookshop_component_browser %} tag. The new tag requires no arguments.

  • eleventy: The @bookshop/cloudcannon-eleventy-bookshop plugin is now superseded by the bookshop/generate npm package. See the Bookshop 3.0 migration guide for more information.

  • jekyll: The cloudcannon-jekyll-bookshop plugin is now superseded by the bookshop/generate npm package. See the Bookshop 3.0 migration guide for more information.

  • jekyll: For data to be accessible when live editing, you will need to set data_config: true in your cloudcannon.config.* file.

  • jekyll: Some collection fields such as page.content and page.excerpt are no longer available when live editing.

  • jekyll: Data and collections are no longer accessible from the component browser.

2.6.1 (2022-03-03)

Bug Fixes

  • eleventy: fixes live rendering of string arguments (1e5b979)
  • jekyll/eleventy: multiline assign tags now render correctly (2756be2)
  • jekyll: fail markdownify gracefully if the input is undefined (3238f8d)

2.6.0 (2022-02-25)

Bug Fixes

  • bookshop tags can now be broken up onto multiple lines in all ssgs (9ea3462)
  • bookshop tags can now be called without props in all ssgs (3e370e8)
  • browser: prevent compression of the bookshop browser javascript (ba132d9)
  • hugo: components passed params directly would not get a binding (77ec44b)
  • hugo: hugo partials passed only a string would error in live editor (8ae7e67)
  • hugo: improve complex templating support in the live editor (5706627)
  • hugo: iterating over a map now works correctly when live editing (408573f)
  • hugo: reduce errors when using assigned variables in components (e6a85c2)
  • live: downgrade data binding errors to console warnings (66e9dfe)

Features

  • generate: add flags to skip default steps (8660328)
  • live: opt-out of live rendering with the live_render flag in props (939be4c)

Performance Improvements

  • live: improve performance by throttling renders (c34e2d4)

2.5.0 (2022-02-22)

Bug Fixes

  • hugo: bundle hugo correctly when running local component browser (089dcf3)
  • match hugo's (bizzare) handling of short markdown strings (f14261f)

Features

2.4.2 (2022-02-02)

Features

  • hugo-engine: implement many transforms for hugo live editing (98024f8)
    • Now supported:

      • markdownify
      • plainify
      • emojify
      • htmlEscape
      • htmlUnescape
      • *highlight
    • markdownify uses a different implementation than hugo, so the output is not guaranteed to be identical.

    • *highlight is not supported, but will no longer error. It will now pass through the input unchanged.

  • jekyll-engine: implement markdownify for jekyll live editing (53af90d)
    • markdownify uses a different kramdown implementation than jekyll, so the output is not guaranteed to be identical.

2.4.1 (2022-02-01)

Features

  • attempt to load the hugo wasm from a cdn where possible (8423acb)

2.4.0 (2022-01-31)

Bug Fixes

  • fix complex assignments and loops that were breaking live editing in Jekyll and Eleventy
  • fix initial render of data bindings on Jekyll sites that load external data
  • improved resolution of complex data bindings

Features

  • Hugo Bookshop support 🎉
  • Hugo live editing beta 🎉
  • Hugo component browser beta 🎉
  • new method of updating the page when live editing — image flickering should be greatly reduced
  • new @bookshop/generate command for structures and live editing — Jekyll and Eleventy documentation to come

2.3.1 (2022-01-19)

Bug Fixes

  • live rendering error boundary around bad comments (91e77f1)

2.3.0 (2022-01-19)

Features

  • generate: add new structures cli to replace cc-ssg plugins (8a4bff3)

2.2.3 (2021-12-14)

Bug Fixes

  • live: patch for complex layouts assigning html to variables (#76) (0a90a4d)

2.2.2 (2021-12-08)

Features

  • support _editor_link and _editorLink as flags in component data (1fa8591)

2.2.1 (2021-12-07)

Bug Fixes

  • handle some editor link corner cases (a45653a)

Features

  • editor links can be toggled on a per-component basis by setting the editor_links or editorLinks flag in a components props

2.2.0 (2021-12-05)

Features

  • live: automatically add cms editor links in the live renderer (08fa8b3)

This will take effect with the upcoming CloudCannon editor panels release.

2.1.1 (2021-11-16)

Bug Fixes

  • init: fix arguments to @bookshop/init command (c15282d)

2.1.0 (2021-11-16)

Bug Fixes

  • eleventy: make eleventy engine more lenient for dynamic components (f6de1f0)

Features

  • eleventy: eleventy 1.0.0-beta support (35fce81)
  • hugo: core hugo component support (#60) (75a9765)
  • init: renamed the @bookshop/gen package to @bookshop/init (86ad798)

2.0.10 (2021-10-29)

  • no-op release to reset npm latest tag

2.0.9 (2021-10-13)

Bug Fixes

  • eleventy-bookshop: correctly handle nested liquidjs contexts (c4899f7)
  • toml-narrator: fix quotes in TOML comments (50992f2)

2.0.8 (2021-10-12)

Bug Fixes

  • live: wrong injected window variable (d226bcd)

2.0.7 (2021-10-11)

Bug Fixes

  • jekyll-engine: correct jekyll highlight tag implementation (020d8c2)
  • live: handle more live editing edge cases (9ee51c0)

2.0.6 (2021-10-08)

Bug Fixes

  • normalize paths for fast-glob on windows (d37e9ed)
  • use patched node-runner while awaiting next publish (d98a91b)

2.0.5 (2021-10-06)

Features

  • automatically set the array structure id_key for components (e9a1650)

2.0.4 (2021-10-06)

Bug Fixes

  • live rendering name parsing edge cases (f7badef)

2.0.3 (2021-10-05)

Bug Fixes

  • retry components that error in jekyll due to a thread race (1cc3172)

2.0.2 (2021-10-05)

Bug Fixes

  • Fix incorrect live rendering behavior for @bookshop/live

2.0.1 (2021-10-05)

Features

  • Provide an optional hosted component library outside of the website when running npx @bookshop/live
  • Introduced npx @bookshop/gen command

2.0.0 (2021-10-05)

  • Initial stable release for Jekyll and Eleventy