Layout presets for Hyper.app
$ npm install -g hyperlayout hpm-cli
$ hpm install hyperlayout
To get started, setup a layout inside of package.json
.
Alternatively you can define it in .hyperlayout
or ~/.hyperlayout
.
package.json
{
"name": "example-1",
"hyperlayout": [
[
"echo 'Hello'",
"echo 'World'"
]
]
}
To apply the layout, simply run hyperlayout
in the same directory.
$ hyperlayout
This example shows the capabilities of hyperlayout
.
package.json
{
"name": "example-2",
"scripts": {
"watch": "gulp watch",
"serve": "nodemon build/index"
},
"hyperlayout": {
"start": [
[[
"npm run watch",
["npm run serve", "http://localhost:3000"]
]],
"mongod"
],
"helloworld": {
"entry": "horizontal",
"layout": [
"echo 'Hello'",
"echo 'World'"
]
}
}
}
Since there are two layouts defined here, you have to tell hyperlayout
which one you want to use, by suppling it as parameter.
$ hyperlayout start
["1", "2"]
[["1", "2"]]
or
{
"entry": "horizontal",
"layout": ["1", "2"]
}
[[["1", "2"]]]
or
{
"entry": "vertical",
"layout": ["1", "2"]
}
- It isn't possible layout multiple windows at once. If you know how to approach this feature, then head over to Issue #2 and let me know!
hyperlayout
was written by Timo Lins.
Special thanks to Tobias Lins, for coming up with some great solutions.