Skip to content
This repository has been archived by the owner on Sep 7, 2020. It is now read-only.

Releases: MoOx/phenomic

v1.0.0-alpha.13

19 Oct 07:18
Compare
Choose a tag to compare
v1.0.0-alpha.13 Pre-release
Pre-release

🎉 No breaking changes 🎉

Main reason of this release is the scalability issue: you can now build a website with hundreds of pages.
Pre-rendering step takes around 4s for 1000 pages 😁

🐛 Bugfix

👍 Improvement

✨ New feature

🌟 New Example

👌 Improved Examples

v1.0.0-alpha.12

11 Oct 07:18
Compare
Choose a tag to compare
v1.0.0-alpha.12 Pre-release
Pre-release

🎉 No breaking changes 🎉

Only good stuff!

Notable additions & changes:

🔥 New plugin

🌟 New Example

⚠️ WARNING: This example can blow you mind as it can show you things you were not prepared to. ⚠️

🐛 Bugfixes

👍 Improvements

v1.0.0 Super Alpha XI

30 Sep 20:19
Compare
Choose a tag to compare
v1.0.0 Super Alpha XI Pre-release
Pre-release

💥 Minor breaking change

🐛 Bugfix

1.0.0 Super Alpha X

27 Sep 20:40
Compare
Choose a tag to compare
1.0.0 Super Alpha X Pre-release
Pre-release

Because it’s a trend to skip version 9, we are bumping from alpha.8 to alpha.10 (pronounced “alpha X”).

phenomic-x


😍 Phenomic was already React 16 ready thanks to our architecture. We are now fully compatible (= no warnings)

💥 2 minor breaking changes

🐛 Bugfixes

👍 Improvements

✨ New (AWESOME) feature 🔥

v1.0.0-alpha.8

16 Sep 20:35
Compare
Choose a tag to compare

v1.0.0-alpha.7

15 Sep 10:31
Compare
Choose a tag to compare
v1.0.0-alpha.7 Pre-release
Pre-release

🎉 No breaking changes 🎉

Only fixes & improvements!


v1.0.0-alpha.6

08 Sep 05:41
Compare
Choose a tag to compare
v1.0.0-alpha.6 Pre-release
Pre-release

We have made some tiny breaking changes (easy to update) for a better future (to give you more power (eg: query for sub-folder & choice for whatever css-in-js solution you want :)

We have added plenty of examples. Be sure to take a look!

FYI, those examples will always be up to date with Phenomic API as those are automatically tested in our full test suit (with some assertions to check the result)!

tl;dr

💥 Breaking change

  • collection concept has been replaced by a simple path.
  • Html component must be in its own file & offers controls for rendering of the HTML (eg: for CSS-in-JS static rendering), see details below.
  • Some change simple have been made for API of render plugins (if you wrote one, let us know!).

✨ New features

  • JS/CSS now have hashes in the filename to avoid caching issues.
  • CSS files can now be easily injected in the Html.
  • Some enhancements on webpack default config.
  • React plugin now exports a function to render content as raw text (handy for meta description & similar)

Details

@phenomic/core

  • 💥 Breaking change we changed a little renderer plugin API:
    • renderServer becomes renderStatic
    • renderHTML is now hidden and replaced by renderDevServer method that accept assets (key: array of filenames) returned by build or injected by addDevServerMiddlewares in res.locals.assets
      (@MoOx)
  • 💥 Breaking change collection concept has been replaced by a simple path. You can just replace all collection in your query by path and it should work. What you are winning here is the ability to query using a sub-folder.

@phenomic/plugin-bundler-webpack

  • Upgrade to webpack@^3.0.0. It's a bit faster on our website (28s vs 24s - Phenomic part is > 2s).
    (#1137 - @MoOx)
  • Properly pass assets to the core (so CSS and JS files are known)
    (@MoOx)

@phenomic/plugin-renderer-react & @phenomic/preset-react-app

  • 💥 Breaking change props passed to Html components are now components to render & not string.
    This will allow people to wrap rendering (eg: so they can use whatever CSS-in-JS solutions).

Previously, a minimal Html component was like

const Html = (props) =>
  <html>
    <head>
      <meta charSet="utf-8" />
      <meta name="viewport" content="width=device-width, initial-scale=1" />
    </head>
    <body className="wrapper">
      {props.body}
      {props.state}
      {props.script}
    </body>
  </html>;

Now it should be

const Html = ({ App, render }) => {
  const { Main, State, Script, Style } = render(<App />);
  // you have also an `assets` object if you want more control to renders js/css files
  return (
    <html>
      <head>
        <meta charSet="utf-8" />
        <meta name="viewport" content="width=device-width, initial-scale=1" />
        <Style />
      </head>
      <body className="wrapper">
        <Main />
        <State />
        <Script />
      </body>
    </html>
  );

(#1094 - @MoOx)

  • A new textRenderer to convert page content to raw text is now export.
import {
  createApp,
  createContainer,
  query,
  BodyRenderer,
/***** I AM NEW *****/
  textRenderer,
/********************/
} from "@phenomic/preset-react-app/lib/client";
// also available from "@phenomic/plugin-renderer-react/lib/client"

const BlogPost = ({ isLoading, page }) => (
  <div>
    {isLoading && "Loading..."}
    {!isLoading &&
    page.node && (
      <article>
        <Head>
          <title>{page.node.title}</title>
/***** TRY ME *****/
          <meta name="description" content={ textRenderer(page.node.body).slice(0, 150) + "…" } />
/******************/
        </Head>
        <h1>{page.node.title}</h1>
        <BodyRenderer>{page.node.body}</BodyRenderer>
      </article>
    )}
    {/* ... */}
  </div>
);

(#1084 - @MoOx)

0.21.2

25 Aug 08:38
Compare
Choose a tag to compare
  • Fixed: fix for bad unicode characters in the markdown and JSON.stringify
    (#1128 - @revolunet)

v1.0.0-alpha.5

09 Aug 21:30
Compare
Choose a tag to compare
v1.0.0-alpha.5 Pre-release
Pre-release

🎉 We added examples in examples/* for react-app and reason-react-app.

We also have prepared a workflow to be able to quickly add more examples with
automated testing to prevent any kind of regressions.
Documentation is also covered by tests to prevent regressions.

Stay tuned for more examples. And do not hesitate to add some!

Do not hesitate to contact us if you want to contribute as our CONTRIBUTING.md is still a WIP :)

tl;dr;

  • Tons of fixes in Getting Started
  • Fixed & improved pagination and static rendering
  • Examples for preset-react-app & reason
  • Client side navigation enabled for markdown link
  • "Various fixes" 🙃

Notable fixes & improvements

@phenomic/core

  • Fix static rendering for collection items (when no by param is used)
    (#1114 - @MoOx)

  • Fix pagination previous that was incorrect for second page
    (@MoOx)

  • Fix order: 'asc' for queries
    (@MoOx)

  • Pre-rendering now handle ALL possible pages for pagination.
    This is a huge step forward as we now have a real immutable pagination that
    opens a number of possibilities like infinite scrolling mixed with immutable
    pages urls!
    (@MoOx, @bloodyowl)

@phenomic/plugin-public-assets

  • Prevent infinite static build step if no "public" folder exist
    (@MoOx)

@phenomic/plugin-bundler-webpack

  • Only shallow error if config file does not exist
    (#1085 - @MoOx)

@phenomic/plugin-renderer-react

  • New Link component that you should use instead of react-router v3 one.
    It enables client side routing for markdown by default and
    also handle relative and external urls unlike react-router v3 Link.
    (@MoOx)

@phenomic/preset-react-app

@phenomic/reason

PR #1111

v1.0.0-alpha.4

11 Jul 16:04
Compare
Choose a tag to compare
v1.0.0-alpha.4 Pre-release
Pre-release

fix(@phenomic/core): support static rendering of "by" parameters for main (first) collection
collection params in routes is now useless as we consider the first collection of the queries as the main query.
(@MoOx)

feat(@phenomic/cli): add a default babel config
(#1071 - @MoOx)

feat(@phenomic/plugin-renderer-react): render path that finish with html as is
(#1106 - @MoOx)

fix(@phenomic/plugin-renderer-react): Prevent our react context usage from colliding with redux
(#1086 - @bloodyowl)