You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+37-51Lines changed: 37 additions & 51 deletions
Original file line number
Diff line number
Diff line change
@@ -1,54 +1,34 @@
1
1
# What is this:
2
2
3
-
This is a single page repo showing how to integrate a model with a view.
3
+
Hey, welcome!
4
4
5
-
It uses a new approach for drawing a model in the AS tests/ dir:
5
+
This is a collection of one page AgemtScript models along with their views and additional tools from the [AgentScript repo](https://github.com/backspaces/agentscript).
6
6
7
-
import TwoDraw from 'https://backspaces.github.io/agentscript/tests/TwoDraw.js'
7
+
Here's the onepagers repo: [https://github.com/backspaces/onepager](https://github.com/backspaces/onepager)
8
8
9
-
It works by creating a properties object describing how to "draw" the model.
9
+
## Here's how to start a git project, like this one:
10
10
11
-
It is very experimental and it is showing me lots of issues. That's what this is all about, right?
12
-
13
-
See the repo: https://github.com/backspaces/virus
14
-
15
-
Run the model using TwoView: https://backspaces.github.io/virus/
16
-
17
-
Add any queryString to use TwoDraw: https://backspaces.github.io/virus/?foo
18
-
19
-
# Init:
20
-
21
-
- cd ~/src
22
-
- mkdir virus
23
-
- cd virus
24
-
- code .
25
-
- touch README.md
26
-
27
-
Then
28
-
29
-
- copy/modify VirusModel.js index.html from AS;
30
-
- server.js from Josh
31
-
32
-
Files are:
33
-
34
-
- VirusModel.js: From agentscript/models, imports modified
- runModel.js: An async runner: run(ModelClass, ViewOptions, DrawOptions)
37
-
38
-
Also:
11
+
```
12
+
cd ~/src
13
+
mkdir onepagers
14
+
cd onepagers
15
+
touch README.md
16
+
copy/install a server for locally testing.
17
+
```
39
18
40
-
- README.md // this file
41
-
- server.js // Josh's http server
19
+
I grabbed a very simple & readable, server.js, from Redfish. You can copy it from the onepagers repo.
42
20
43
-
Run via:
21
+
Run it via:
44
22
45
-
- node < server.js &
46
-
- browser: http://localhost:9000/virus.html .. or whatever page you wan
47
-
- Open console for debug info
23
+
```
24
+
node < server.js &
25
+
browser: http://localhost:9000/\<my model\>.html
26
+
Open console for debug info
27
+
```
48
28
49
-
# Workflow:
29
+
##Workflow:
50
30
51
-
Turn into git repo:
31
+
Turn your directory into git repo:
52
32
53
33
```
54
34
git init
@@ -66,22 +46,28 @@ git add .
66
46
git commit -m "first commit"
67
47
```
68
48
69
-
Integrate with github:
49
+
## Integrate with github:
50
+
51
+
Go to your github account, for me https://github.com/backspaces/
52
+
53
+
Use the + button to add a new repo in my case onepagers. This creates [https://github.com/backspaces/onepagers](https://github.com/backspaces/onepagers)
0 commit comments