Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tanc/rbg-proposal
The proposed theme and pattern library approach
https://github.com/tanc/rbg-proposal
Last synced: about 21 hours ago
JSON representation
The proposed theme and pattern library approach
- Host: GitHub
- URL: https://github.com/tanc/rbg-proposal
- Owner: tanc
- License: gpl-2.0
- Created: 2024-10-12T09:59:15.000Z (4 months ago)
- Default Branch: main
- Last Pushed: 2024-10-15T15:09:33.000Z (4 months ago)
- Last Synced: 2024-12-01T19:14:12.708Z (about 2 months ago)
- Language: JavaScript
- Size: 4.2 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# LocalGov and Storybook
This repo is a starting point for setting up a LocalGov and Storybook integration.
## Set up for development
To get set up locally you can run:
```
ddev start
ddev composer install
sed -i '/function localgov_install() {/,/^}/d' web/profiles/contrib/localgov/localgov.install
ddev drush si --existing-config -y --config-dir=../config/sync
```You'll need to activate development services and its easiest to do this copying
in the example local settings file:```
cp web/sites/example.settings.local.php web/sites/default/settings.local.php
```The Drupal site should be available at https://localgov-storybook.ddev.site
## Development
To put Storybook in development mode you can run
```
ddev storybook dev
```Storybook will now be available at https://localgov-storybook.ddev.site:6006
In another terminal run the drush watch command with:
```
ddev storybook watch
```Now you can create and edit stories (located in `web/themes/custom/greenwich_base/stories`) and they
should be added to Storybook. In some situations you'll need to manually refresh Storybook
to see the updates.## Hosting storybook
There is a `docker-compose.yml` file and supporting files in the `.build` directory.
To use them you can do the following:
```
cp .build/env.example .build/.env
docker-compose -f .build/docker-compose.yml -f .build/docker-compose.caddy.yml up
```This should build the container images and run them.
You will need to point the following two domains at `127.0.0.1` in your hosts file:
```
drupal-storybook.localhost
storybook.localhost
```You should then be able to view the storybook site at http://storybook.localhost:8088