bionic
bionic copied to clipboard
** Bionic - An Ionic CLI clone for Blazor projects ** moved to:
Bionic has a new home:
*** THIS PROJECT MOVED AND THIS REPO WILL SOON BE REMOVED***
Bionic Framework Documentation
Where can I find an updated version of this repo?
-- // --

Build web apps Blazor fast that run at WASM speed!
Bionic: An Ionic CLI clone for Blazor projects
Documentation is now available.
Quick Start
Before we start, make sure that the following tools are available in your system:
-
SASS is installed and available in your terminal path
You can install sass from here. Ensure availability by executing scss command:
scss --version
Ruby Sass 3.5.6
-
NodeJS is installed and available in your terminal path
You can install node from here. Ensure availability by executing node command:
node --version
v9.5.0
npm --version
5.6.0
The following steps are only required to be executed once:
- Create a Blazor App
- Install Bionic from NuGet:
dotnet tool install --global Bionic
- Prepare Blazor project for Bionic:
bionic start
The next steps are part of your day-to-day development:
- Run project:
bionic serve
- In a secondary terminal, cd into your project root directory
- Create a new component:
bionic generate component CounterComponent
- Edit component and reuse it anywhere you want...
Sample Bionic commands
Version
bionic version
Updating Bionic
bionic update
Uninstalling Bionic
bionic uninstall
Using Electron platform plugin
You'll need the following tools installed:
- Recent version of NodeJS installed
bionic platform add electron
bionic platform electron init
bionic platform electron build
bionic platform electron serve
Using Capacitor platform plugin
You'll need the following tools installed:
- Recent version of NodeJS installed
- Android Studio
bionic platform add capacitor
bionic platform capacitor init
bionic platform capacitor android init
bionic platform capacitor android build
bionic platform capacitor android open
Creating Blazor pages
bionic generate page MyPage
Creating Blazor components
bionic generate component MyComponent
Creating Blazor services
bionic generate service MyService
Using Bionic Blast scripts
Blast scripts are easy to use and organize. They are most useful to easily set build sequences.
In your Blazor project Client or Standalone directory, use your favorite text editor or IDE to create or edit .bionic/bionic.blast
Add the following content and save it:
:electron
>electron-init
>electron-build
:electron-init
bionic platform add electron
bionic platform electron init
:electron-build
bionic platform electron build
bionic platform electron serve
Lines starting with:
: - targets
> - sub-targets. Make sure that there are no spaces after it.
Any other type of line is a cli command.
Blast scripts not executing?
There's a bug in dotnet tools that is preventing bionic tool from being found in the system path.
There are several solutions. If you are in OSX, just edit /etc/paths.d/dotnet-cli-tools
to be $HOME/.dotnet/tools
.
Did not try in Linux, but you may have to do the same or just edit your shell init script accordingly.
Then have bionic blast it away: bionic blast electron