Feature Branches

Sygnal's preferred approach is to branch feature development to keep main clean and allow for freedom of experimentation and Webflow designer testing.

Creating a Feature Branch

Create your new feature branch, e.g.;

git checkout -b feature/NAME

Working with a Feature Branch

In VSCode, you'll see the currently selected branch in the bottom-left corner;

Designer-Testing a Feature Branch

Will deploy the lib to your designated workspace, but as a Test version;

  • The Library name will end in Test

  • The Library ID with a -test suffix

In the designer, you'll see your library as e.g. My Library Test v1.0.0 ⚠️

Install or update that library in your test project.

Add any components you want- it will

Merging a Feature Branch into Main

In general we want to keep feature branches clean- so that they only contain the new component(s) you're building or refactoring.

Advanced Merge Notes

Start from your feature branch, e.g.

Make sure everything is committed;

See commits that aren't on main;

See which files have changed;

Examine detailed file changes if you want;

Switch to the main branch;

Merging

In most cases we prefer to preserve branch history.

From the main branch,

Update the version number in src/version.ts

Perform the feature branch merge, e.g.;

Then, usually cleanup by removing the feature branch;

Some alternative merging approaches

You may also be able to fast-forward merge;

Or squash merge ( combine all commits into one );

e.g.;

Final Integration Review

With the feature now merged into main, retest to ensure the integration was successful.

Update the version.ts to reflect the new library version. This will be important for marketplace users, and for multiple-workspace distributions.

Deploy main to your testing workspace.

From main, this will deploy the library under its proper name, without the Test suffix.

Retest.

In the designer, accept the library revisions from the library panel.

  • Replace your Test library components with the production library components.

You can see both libraries, the test and the prod versions;

Important, currently there is no way to distinguish in the designer between test and production component versions, they will look identical in the left nav, and in the properties list during this replacement process.

To simplify this, select the old component, add the new one and it will position directly after. then copy-past your property settings.

Last updated