Skip to content

Commit

Permalink
Added social image
Browse files Browse the repository at this point in the history
  • Loading branch information
oskardudycz committed Feb 10, 2024
1 parent 8211ef0 commit e551336
Show file tree
Hide file tree
Showing 11 changed files with 838 additions and 13 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ jobs:
with:
# use the node version defined in matrix above
node-version: ${{ matrix.node-version }}
cache: 'npm'

- name: Install dependencies
run: npm ci
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ jobs:
registry-url: 'https://registry.npmjs.org'
- name: Install dependencies and build 🔧
run: npm ci && npm run build
env:
NODE_ENV: production

- name: Set public publishing
run: npm config set access public
Expand All @@ -22,3 +24,4 @@ jobs:
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NODE_ENV: production
3 changes: 2 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
"editor.tabSize": 2,

"files.exclude": {
"node_modules/": true
"node_modules/": true,
"**/node_modules/": true
// "dist/": true
},
"files.eol": "\n",
Expand Down
53 changes: 53 additions & 0 deletions docs/.vitepress/config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ const env = process.env.NODE_ENV;
// https://vitepress.dev/reference/site-config
export default defineConfig({
base: env === 'production' ? '/emmett/' : '/',
lang: 'en-GB',
title: 'Emmett',
description: 'Event Sourcing made simple',
themeConfig: {
Expand All @@ -25,8 +26,60 @@ export default defineConfig({
},
],

search: {
provider: 'local',
},

editLink: {
pattern:
'https://github.com/event-driven-io/emmett/edit/master/docs/:path',
text: 'Suggest changes to this page',
},

socialLinks: [
{ icon: 'github', link: 'https://github.com/event-driven-io/emmett' },
],
footer: {
copyright: 'Copyright © Oskar Dudycz and contributors.',
},
},
head: [
// ['link', { rel: 'apple-touch-icon', type: 'image/png', size: "180x180", href: '/apple-touch-icon.png' }],
// ['link', { rel: 'icon', type: 'image/png', size: "32x32", href: '/favicon-32x32.png' }],
// ['link', { rel: 'icon', type: 'image/png', size: "16x16", href: '/favicon-16x16.png' }],
// ['link', { rel: 'manifest', manifest: '/manifest.json' }],
['meta', { property: 'og:title', content: 'Emmett' }],
['meta', { property: 'og:type', content: 'website' }],
[
'meta',
{
property: 'og:description',
content: 'Event Sourcing development made simple',
},
],
[
'meta',
{
property: 'og:image',
content: 'https://event-driven-io.github.io/emmett/social.png',
},
],
[
'meta',
{
property: 'og:url',
content: 'https://event-driven-io.github.io/emmett',
},
],
['meta', { property: 'twitter:card', content: 'summary_large_image' }],
['meta', { property: 'twitter:site', content: 'marten_lib' }],
['meta', { property: 'twitter:creator', content: 'marten_lib' }],
[
'meta',
{
property: 'twitter:image',
content: 'https://event-driven-io.github.io/emmett/social.png',
},
],
],
});
28 changes: 27 additions & 1 deletion docs/getting-started.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,35 @@

Yet, some say that's complex and complicated; Emmett aims to prove that it doesn't have to be like that. We cut the boilerplate and layered madness, letting you focus on delivery. We're opinionated but focus on composition, not magic. Let me show you how.

## Installation

Before we dive into the real world's scenario, let's add Emmett to your project, as we'll use its types and tooling to streamline the development effort.

I assume that you have Node.js installed. Add the package from the terminal using your favourite package manager:

::: code-group

```sh [npm]
$ npm add -D @event-driven-io/emmett
```

```sh [pnpm]
$ pnpm add -D @event-driven-io/emmett
```

```sh [yarn]
$ yarn add -D @event-driven-io/emmett
```

```sh [bun]
$ bun add -D @event-driven-io/emmett
```

:::

## Events

Events are the centrepiece of event-sourced systems. They represent both critical points of the business process but are also used as the state. That enables you to reflect your business into the code better, getting the synergy. Let's model a simple business process: a shopping cart. You can open it, add or remove the product from it and confirm or cancel.
**Events are the centrepiece of event-sourced systems.** They represent both critical points of the business process but are also used as the state. That enables you to reflect your business into the code better, getting the synergy. Let's model a simple business process: a shopping cart. You can open it, add or remove the product from it and confirm or cancel.

We could define it as follows:

Expand Down
Binary file added docs/public/social.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit e551336

Please sign in to comment.