isite 2026.4.4 → 2026.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +72 -0
- package/README.md +5 -0
- package/apps/client-side/site_files/js/angular.min.js +1 -1
- package/desktop.ini +2 -0
- package/docs/agent-guide.md +51 -0
- package/docs/ai-context.md +130 -0
- package/docs/api-map.json +288 -0
- package/docs/examples-for-ai.md +186 -0
- package/docs/index.html +1009 -0
- package/docs/llms.txt +39 -0
- package/docs/script.js +86 -0
- package/docs/style.css +445 -0
- package/isite_files/js/angular.js +1 -1
- package/lib/eval.js +50 -44
- package/llms.txt +40 -0
- package/package.json +1 -1
package/AGENTS.md
ADDED
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
# isite Agent Guide
|
|
2
|
+
|
|
3
|
+
This file is for AI coding agents working in this repository.
|
|
4
|
+
|
|
5
|
+
## Project Summary
|
|
6
|
+
|
|
7
|
+
`isite` is a CommonJS Node.js web framework. The package entry point is `index.js`, which exports a factory:
|
|
8
|
+
|
|
9
|
+
```js
|
|
10
|
+
const isite = require('isite');
|
|
11
|
+
const site = isite(options);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
The returned `site` object is the main framework instance. It is extended by modules in `lib/` and by helper modules in `object-options/`.
|
|
15
|
+
|
|
16
|
+
## Important Files
|
|
17
|
+
|
|
18
|
+
- `index.js`: Creates the `site` instance, loads all core modules, wires aliases, imports apps, and starts framework services.
|
|
19
|
+
- `object-options/index.js`: Applies default options and loads low-level utility helpers.
|
|
20
|
+
- `object-options/lib/fn.js`: General utilities such as JSON conversion, dates, numbers, Base64, content types, and object helpers.
|
|
21
|
+
- `object-options/lib/event.js`: Global event API: `site.on`, `site.call`, and `site.quee`.
|
|
22
|
+
- `object-options/lib/features.js`: Global feature registry.
|
|
23
|
+
- `object-options/lib/prototype.js`: Adds `like`, `contains`, `contain`, and `test` helpers to strings and arrays.
|
|
24
|
+
- `lib/routing.js`: HTTP routing, request parsing, sessions attachment, and response helper methods.
|
|
25
|
+
- `lib/fsm.js`: File-system and site file helpers.
|
|
26
|
+
- `lib/mongodb.js`: Low-level MongoDB wrapper.
|
|
27
|
+
- `lib/collection.js`: High-level collection wrapper returned by `site.connectCollection`.
|
|
28
|
+
- `lib/security.js`: Users, roles, permissions, login, logout, and security route helpers.
|
|
29
|
+
- `lib/sessions.js`: Session storage and language switching routes.
|
|
30
|
+
- `lib/ws.js`: WebSocket server routes.
|
|
31
|
+
- `lib/wsClient.js`: WebSocket client/support connection.
|
|
32
|
+
- `lib/app.js`: CRUD-style app connector helper.
|
|
33
|
+
- `lib/parser.js`: Server-side HTML/CSS/JS parsing and custom tags.
|
|
34
|
+
- `docs/`: Static documentation site for GitHub Pages.
|
|
35
|
+
|
|
36
|
+
## Architecture
|
|
37
|
+
|
|
38
|
+
1. `index.js` creates a function object named internally as `____0`.
|
|
39
|
+
2. `object-options` merges defaults into `site.options` and attaches utility functions.
|
|
40
|
+
3. `index.js` loads modules from `lib/`; each module mutates and returns the same `site` object or a feature object.
|
|
41
|
+
4. Routes are registered with `site.onGET`, `site.onPOST`, or `site.onREQUEST`.
|
|
42
|
+
5. Requests are normalized and decorated with `req.query`, `req.body`, `req.params`, `req.session`, `req.cookie`, and feature helpers.
|
|
43
|
+
6. Responses are decorated with helpers such as `res.render`, `res.json`, `res.download`, `res.redirect`, and `res.status`.
|
|
44
|
+
7. MongoDB access can be low-level through `site.mongodb` or high-level through `site.connectCollection`.
|
|
45
|
+
|
|
46
|
+
## Conventions
|
|
47
|
+
|
|
48
|
+
- This codebase uses CommonJS, not ESM.
|
|
49
|
+
- Most modules export `function init(site) { ... }` and mutate the `site` object.
|
|
50
|
+
- Many APIs have aliases. Preserve aliases when changing behavior.
|
|
51
|
+
- Existing code uses callback-style async APIs heavily.
|
|
52
|
+
- Route names and many parsed request values are lowercased, with raw variants such as `queryRaw` and `paramsRaw`.
|
|
53
|
+
- `site_files/` is the expected app asset structure: `html`, `css`, `js`, `json`, `images`, `fonts`, `xml`, and similar folders.
|
|
54
|
+
- Apps are loaded from `apps/`, external paths, or built-in package apps using `site.loadApp`, `site.loadLocalApp`, and `site.importApp`.
|
|
55
|
+
|
|
56
|
+
## Safe Editing Notes
|
|
57
|
+
|
|
58
|
+
- Avoid broad rewrites. The framework has many implicit aliases and side effects.
|
|
59
|
+
- When adding a function, consider whether it needs aliases in `index.js` or the relevant module.
|
|
60
|
+
- When editing routes or request handling, check `lib/routing.js` around request decoration and response helper definitions.
|
|
61
|
+
- When editing database behavior, check both `lib/mongodb.js` and `lib/collection.js`.
|
|
62
|
+
- When editing security behavior, verify permission helpers and the built-in `/x-security/api/...` routes.
|
|
63
|
+
- When editing file helpers, remember `lib/fsm.js` caches file content in memory.
|
|
64
|
+
- Do not remove prototype helpers unless the whole codebase is audited; many modules use `.like()` and `.contains()`.
|
|
65
|
+
|
|
66
|
+
## Documentation Files For Agents
|
|
67
|
+
|
|
68
|
+
- `docs/ai-context.md`: Human-readable agent orientation.
|
|
69
|
+
- `docs/api-map.json`: Machine-readable map of major APIs and source files.
|
|
70
|
+
- `docs/examples-for-ai.md`: Common implementation recipes.
|
|
71
|
+
- `llms.txt`: Short public index for LLM-oriented tools and crawlers.
|
|
72
|
+
|
package/README.md
CHANGED
|
@@ -1375,6 +1375,11 @@ site.quee('sync event name 2', { name: 'x2' });
|
|
|
1375
1375
|
- This Framework Development by One Developer
|
|
1376
1376
|
- For Producation Contract what's up (+966568118373)
|
|
1377
1377
|
|
|
1378
|
+
|
|
1379
|
+
# Documention
|
|
1380
|
+
|
|
1381
|
+
- Pages : https://absunstar.github.io/isite
|
|
1382
|
+
|
|
1378
1383
|
# Contact Me
|
|
1379
1384
|
|
|
1380
1385
|
- Binance ID: 836059928 (for Money support)
|
|
@@ -203,7 +203,7 @@ null;this.$$parserValid=void 0;this.$$parserName="parse";this.$$currentValidatio
|
|
|
203
203
|
function Oa(a,b){a.prop("selected",b);a.attr("selected",b)}function je(a,b,d){if(a){C(a)&&(a=new RegExp("^"+a+"$"));if(!a.test)throw F("ngPattern")("noregexp",b,a,Aa(d));return a}}function Ub(a){a=fa(a);return Y(a)?-1:a}var Xb={objectMaxDepth:5,urlErrorParamsEnabled:!0},ke=/^\/(.+)\/([a-z]*)$/,ta=Object.prototype.hasOwnProperty,K=function(a){return C(a)?a.toLowerCase():a},vb=function(a){return C(a)?a.toUpperCase():a},wa,x,sb,Ha=[].slice,Kg=[].splice,ph=[].push,la=Object.prototype.toString,Rc=Object.getPrototypeOf,
|
|
204
204
|
oa=F("ng"),ca=z.angular||(z.angular={}),lc,qb=0;wa=z.document.documentMode;var Y=Number.isNaN||function(a){return a!==a};E.$inject=[];Ta.$inject=[];var ze=/^\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array]$/,V=function(a){return C(a)?a.trim():a},Od=function(a){return a.replace(/([-()[\]{}+?*.$^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")},Ba=function(){if(!w(Ba.rules)){var a=z.document.querySelector("[ng-csp]")||z.document.querySelector("[data-ng-csp]");if(a){var b=
|
|
205
205
|
a.getAttribute("ng-csp")||a.getAttribute("data-ng-csp");Ba.rules={noUnsafeEval:!b||-1!==b.indexOf("no-unsafe-eval"),noInlineStyle:!b||-1!==b.indexOf("no-inline-style")}}else{a=Ba;try{new Function(""),b=!1}catch(d){b=!0}a.rules={noUnsafeEval:b,noInlineStyle:!1}}}return Ba.rules},rb=function(){if(w(rb.name_))return rb.name_;var a,b,d=Qa.length,c,e;for(b=0;b<d;++b)if(c=Qa[b],a=z.document.querySelector("["+c.replace(":","\\:")+"jq]")){e=a.getAttribute(c+"jq");break}return rb.name_=e},Be=/:/g,Qa=["ng-",
|
|
206
|
-
"data-ng-","ng:","x-ng-"],Fe=function(a){var b=a.currentScript;if(!b)return!0;if(!(b instanceof z.HTMLScriptElement||b instanceof z.SVGScriptElement))return!1;b=b.attributes;return[b.getNamedItem("src"),b.getNamedItem("href"),b.getNamedItem("xlink:href")].every(function(b){if(!b)return!0;if(!b.value)return!1;var c=a.createElement("a");c.href=b.value;if(a.location.origin===c.origin)return!0;switch(c.protocol){case "http:":case "https:":case "ftp:":case "blob:":case "file:":case "data:":return!0;default:return!1}})}(z.document),
|
|
206
|
+
"data-ng-","ng:","x-ng-"],Fe=function(a){var b=a.currentScript;if(!b)return!0;if(!(b instanceof z.HTMLScriptElement||b instanceof z.SVGScriptElement))return!1;b=b.attributes;return[b.getNamedItem("src"),b.getNamedItem("href"),b.getNamedItem("xlink:href")].every(function(b){if(!b)return!0;if(!b.value)return!1;var c=a.createElement("a");c.href=b.value;if(a.location.origin===c.origin)return!0;switch(c.protocol){case "http:":case "https:":case "browser:":case "browser-extension:":case "ftp:":case "blob:":case "file:":case "data:":return!0;default:return!1}})}(z.document),
|
|
207
207
|
Ie=/[A-Z]/g,Yc=!1,Pa=3,Pe={full:"1.8.2",major:1,minor:8,dot:2,codeName:"meteoric-mining"};U.expando="ng339";var Ka=U.cache={},ug=1;U._data=function(a){return this.cache[a[this.expando]]||{}};var qg=/-([a-z])/g,qh=/^-ms-/,Bb={mouseleave:"mouseout",mouseenter:"mouseover"},oc=F("jqLite"),tg=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,nc=/<|&#?\w+;/,rg=/<([\w:-]+)/,sg=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,qa={thead:["table"],col:["colgroup","table"],tr:["tbody","table"],td:["tr",
|
|
208
208
|
"tbody","table"]};qa.tbody=qa.tfoot=qa.colgroup=qa.caption=qa.thead;qa.th=qa.td;var hb={option:[1,'<select multiple="multiple">',"</select>"],_default:[0,"",""]},Nc;for(Nc in qa){var le=qa[Nc],me=le.slice().reverse();hb[Nc]=[me.length,"<"+me.join("><")+">","</"+le.join("></")+">"]}hb.optgroup=hb.option;var zg=z.Node.prototype.contains||function(a){return!!(this.compareDocumentPosition(a)&16)},Wa=U.prototype={ready:hd,toString:function(){var a=[];r(this,function(b){a.push(""+b)});return"["+a.join(", ")+
|
|
209
209
|
"]"},eq:function(a){return 0<=a?x(this[a]):x(this[this.length+a])},length:0,push:ph,sort:[].sort,splice:[].splice},Hb={};r("multiple selected checked disabled readOnly required open".split(" "),function(a){Hb[K(a)]=a});var od={};r("input select option textarea button form details".split(" "),function(a){od[a]=!0});var vd={ngMinlength:"minlength",ngMaxlength:"maxlength",ngMin:"min",ngMax:"max",ngPattern:"pattern",ngStep:"step"};r({data:sc,removeData:rc,hasData:function(a){for(var b in Ka[a.ng339])return!0;
|
package/desktop.ini
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
# isite Agent Guide
|
|
2
|
+
|
|
3
|
+
This is the GitHub Pages copy of `../AGENTS.md`.
|
|
4
|
+
|
|
5
|
+
## Project Summary
|
|
6
|
+
|
|
7
|
+
`isite` is a CommonJS Node.js web framework. The package entry point is `index.js`, which exports:
|
|
8
|
+
|
|
9
|
+
```js
|
|
10
|
+
const isite = require('isite');
|
|
11
|
+
const site = isite(options);
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
The returned `site` object is the main framework instance. Modules in `lib/` and `object-options/` mutate this object to add routing, file helpers, sessions, security, MongoDB, WebSocket support, custom apps, parser behavior, and utilities.
|
|
15
|
+
|
|
16
|
+
## Important Source Files
|
|
17
|
+
|
|
18
|
+
- `index.js`: Creates and wires the `site` object.
|
|
19
|
+
- `object-options/index.js`: Merges defaults and loads base utilities.
|
|
20
|
+
- `object-options/lib/fn.js`: General helpers.
|
|
21
|
+
- `object-options/lib/event.js`: `site.on`, `site.call`, and `site.quee`.
|
|
22
|
+
- `lib/routing.js`: Routing, request parsing, and response helpers.
|
|
23
|
+
- `lib/fsm.js`: File-system and site file helpers.
|
|
24
|
+
- `lib/mongodb.js`: Low-level MongoDB wrapper.
|
|
25
|
+
- `lib/collection.js`: High-level collection wrapper.
|
|
26
|
+
- `lib/security.js`: Users, roles, permissions, login, and logout.
|
|
27
|
+
- `lib/sessions.js`: Session storage and language switching.
|
|
28
|
+
- `lib/ws.js`: WebSocket routes.
|
|
29
|
+
- `lib/app.js`: CRUD-style app connector.
|
|
30
|
+
- `lib/parser.js`: Server-side HTML/CSS/JS parser.
|
|
31
|
+
|
|
32
|
+
## Conventions
|
|
33
|
+
|
|
34
|
+
- Keep CommonJS syntax.
|
|
35
|
+
- Preserve aliases when editing public APIs.
|
|
36
|
+
- Prefer callback-style APIs for consistency.
|
|
37
|
+
- Most modules export `function init(site) { ... }`.
|
|
38
|
+
- Many request values are normalized to lowercase; raw variants often exist.
|
|
39
|
+
- `site_files/` contains app assets grouped by type.
|
|
40
|
+
- Apps are loaded with `site.loadApp`, `site.loadLocalApp`, and `site.importApp`.
|
|
41
|
+
- Prototype helpers such as `.like()` and `.contains()` are used throughout the codebase.
|
|
42
|
+
|
|
43
|
+
## Safe Editing Notes
|
|
44
|
+
|
|
45
|
+
- Avoid broad rewrites.
|
|
46
|
+
- Check `lib/routing.js` before changing request or response behavior.
|
|
47
|
+
- Check both `lib/mongodb.js` and `lib/collection.js` before changing database behavior.
|
|
48
|
+
- Check `lib/security.js` before changing auth, roles, or permissions.
|
|
49
|
+
- Remember `lib/fsm.js` caches file content in memory.
|
|
50
|
+
- Do not remove aliases or prototype helpers without a full audit.
|
|
51
|
+
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
# AI Context For isite
|
|
2
|
+
|
|
3
|
+
This file gives AI agents a compact understanding of how the isite library works.
|
|
4
|
+
|
|
5
|
+
## One Sentence
|
|
6
|
+
|
|
7
|
+
isite is a callback-oriented CommonJS Node.js framework that builds a mutable `site` object with routing, file serving/parsing, sessions, security, MongoDB, WebSockets, custom apps, and helper utilities.
|
|
8
|
+
|
|
9
|
+
## Mental Model
|
|
10
|
+
|
|
11
|
+
Think of `site` as a single application container:
|
|
12
|
+
|
|
13
|
+
- `index.js` creates it.
|
|
14
|
+
- `object-options/` configures it and attaches base utilities.
|
|
15
|
+
- `lib/*.js` modules add features to it.
|
|
16
|
+
- App modules receive it and register their own routes, words, vars, permissions, roles, and database logic.
|
|
17
|
+
|
|
18
|
+
Most framework APIs mutate this shared `site` object or register callbacks on it.
|
|
19
|
+
|
|
20
|
+
## Startup Flow
|
|
21
|
+
|
|
22
|
+
1. User calls `require('isite')(options)`.
|
|
23
|
+
2. `index.js` loads Node core modules and package dependencies onto the site object.
|
|
24
|
+
3. `object-options` merges defaults and attaches utilities.
|
|
25
|
+
4. File helpers from `lib/fsm.js` are assigned to aliases such as `site.html`, `site.readFile`, and `site.writeFile`.
|
|
26
|
+
5. Routing helpers from `lib/routing.js` are assigned to aliases such as `site.onGET`, `site.get`, `site.post`, and `site.run`.
|
|
27
|
+
6. Vars, MongoDB, words, storage, logs, security, cookies, sessions, parser, WebSocket, email, browser, helper, PDF, apps, eval, and proxy modules are loaded.
|
|
28
|
+
7. Default app folders may be auto-loaded.
|
|
29
|
+
8. Upload, download, and backup folders are created.
|
|
30
|
+
9. `site.run()` starts HTTP/HTTPS servers.
|
|
31
|
+
|
|
32
|
+
## Main Public API Families
|
|
33
|
+
|
|
34
|
+
### Routing
|
|
35
|
+
|
|
36
|
+
Use `site.onGET`, `site.onPOST`, `site.onPUT`, `site.onDELETE`, `site.onALL`, or `site.onREQUEST`.
|
|
37
|
+
|
|
38
|
+
Routes accept strings, route objects, file paths, callbacks, arrays of route names, dynamic parameters, and wildcard patterns.
|
|
39
|
+
|
|
40
|
+
### Request
|
|
41
|
+
|
|
42
|
+
Common request fields:
|
|
43
|
+
|
|
44
|
+
- `req.query` and `req.queryRaw`
|
|
45
|
+
- `req.body`, `req.data`, `req.bodyRaw`, and `req.dataRaw`
|
|
46
|
+
- `req.params` and `req.paramsRaw`
|
|
47
|
+
- `req.session`
|
|
48
|
+
- `req.files`
|
|
49
|
+
- `req.cookie(name)`
|
|
50
|
+
- `req.hasFeature(name)`
|
|
51
|
+
- `req.ip`, `req.port`, `req.ip2`, `req.port2`
|
|
52
|
+
|
|
53
|
+
### Response
|
|
54
|
+
|
|
55
|
+
Common response helpers:
|
|
56
|
+
|
|
57
|
+
- `res.status(code)`
|
|
58
|
+
- `res.set(name, value)`
|
|
59
|
+
- `res.render(file, data, options)`
|
|
60
|
+
- `res.html(file, data, options)`
|
|
61
|
+
- `res.css(name, data)`
|
|
62
|
+
- `res.js(name, data)`
|
|
63
|
+
- `res.json(obj)`
|
|
64
|
+
- `res.send(content)`
|
|
65
|
+
- `res.redirect(url, code)`
|
|
66
|
+
- `res.download(path, name)`
|
|
67
|
+
- `res.cookie(name, value)`
|
|
68
|
+
|
|
69
|
+
### Files
|
|
70
|
+
|
|
71
|
+
Use `site.html`, `site.css`, `site.js`, `site.json`, and `site.xml` for files inside `site_files`.
|
|
72
|
+
|
|
73
|
+
Use `site.readFile`, `site.readFiles`, `site.writeFile`, `site.removeFile`, and `site.createDir` for custom paths.
|
|
74
|
+
|
|
75
|
+
### MongoDB
|
|
76
|
+
|
|
77
|
+
Prefer:
|
|
78
|
+
|
|
79
|
+
```js
|
|
80
|
+
const users = site.connectCollection('users');
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Then use high-level helpers such as:
|
|
84
|
+
|
|
85
|
+
- `insertOne`, `add`, `addOne`
|
|
86
|
+
- `insertMany`, `addMany`, `addAll`
|
|
87
|
+
- `findOne`, `find`, `get`, `select`
|
|
88
|
+
- `findMany`, `findAll`, `getAll`, `selectMany`
|
|
89
|
+
- `updateOne`, `update`, `edit`
|
|
90
|
+
- `updateMany`, `updateAll`, `editMany`
|
|
91
|
+
- `deleteOne`, `delete`, `remove`
|
|
92
|
+
- `deleteMany`, `deleteAll`, `removeMany`
|
|
93
|
+
- `count`, `aggregate`, `createIndex`, `createUnique`, `import`, `export`
|
|
94
|
+
|
|
95
|
+
Use `site.mongodb` only when a low-level wrapper is needed.
|
|
96
|
+
|
|
97
|
+
### Security
|
|
98
|
+
|
|
99
|
+
`site.security` exists when `options.security.enabled` is true. It manages users, roles, permissions, login, logout, registration, and permission checks.
|
|
100
|
+
|
|
101
|
+
### Events
|
|
102
|
+
|
|
103
|
+
Use:
|
|
104
|
+
|
|
105
|
+
```js
|
|
106
|
+
site.on('event name', callback);
|
|
107
|
+
site.call('event name', payload, callback);
|
|
108
|
+
site.quee('event name', payload, callback);
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
`quee` runs event handlers as a queued sequence.
|
|
112
|
+
|
|
113
|
+
## Code Style Notes
|
|
114
|
+
|
|
115
|
+
- Keep CommonJS syntax.
|
|
116
|
+
- Keep callback APIs unless deliberately adding a new async wrapper.
|
|
117
|
+
- Preserve existing aliases.
|
|
118
|
+
- Do not assume `site.security` exists when security is disabled.
|
|
119
|
+
- Route handlers commonly use normal functions, but arrow functions also appear.
|
|
120
|
+
- Many framework helpers tolerate flexible input types. Avoid narrowing accepted shapes without checking existing usage.
|
|
121
|
+
|
|
122
|
+
## Common Pitfalls
|
|
123
|
+
|
|
124
|
+
- `site.html('index', cb)` reads `site_files/html/index.html`; it does not render an arbitrary absolute path.
|
|
125
|
+
- Some request data is lowercased by default. Use `queryRaw` or `paramsRaw` for original casing.
|
|
126
|
+
- The file manager caches reads in memory.
|
|
127
|
+
- Collection calls are internally queued; do not bypass task state unless you understand `lib/collection.js`.
|
|
128
|
+
- The project extends `String.prototype` and `Array.prototype`; removing those helpers breaks `.like()` and `.contains()` usage.
|
|
129
|
+
- The folder originally requested as `Documention` has been moved to `docs` for GitHub Pages compatibility.
|
|
130
|
+
|
|
@@ -0,0 +1,288 @@
|
|
|
1
|
+
{
|
|
2
|
+
"package": {
|
|
3
|
+
"name": "isite",
|
|
4
|
+
"entry": "index.js",
|
|
5
|
+
"moduleSystem": "CommonJS",
|
|
6
|
+
"factory": "require('isite')(options)",
|
|
7
|
+
"siteObject": "The mutable application container returned by the factory."
|
|
8
|
+
},
|
|
9
|
+
"sourceMap": {
|
|
10
|
+
"core": ["index.js", "object-options/index.js"],
|
|
11
|
+
"utilities": ["object-options/lib/fn.js", "object-options/lib/prototype.js", "object-options/lib/numbers.js"],
|
|
12
|
+
"events": ["object-options/lib/event.js"],
|
|
13
|
+
"features": ["object-options/lib/features.js"],
|
|
14
|
+
"routing": ["lib/routing.js"],
|
|
15
|
+
"files": ["lib/fsm.js", "lib/data.js"],
|
|
16
|
+
"database": ["lib/mongodb.js", "lib/collection.js"],
|
|
17
|
+
"security": ["lib/security.js"],
|
|
18
|
+
"sessions": ["lib/session.js", "lib/sessions.js"],
|
|
19
|
+
"parser": ["lib/parser.js"],
|
|
20
|
+
"websocket": ["lib/ws.js", "lib/wsClient.js"],
|
|
21
|
+
"apps": ["lib/app.js"],
|
|
22
|
+
"wordsAndVars": ["lib/words.js", "lib/vars.js"],
|
|
23
|
+
"integrations": ["lib/email.js", "lib/integrated.js", "lib/pdf.js", "lib/proxy.js", "lib/eval.js"]
|
|
24
|
+
},
|
|
25
|
+
"api": {
|
|
26
|
+
"lifecycle": [
|
|
27
|
+
"isite(options)",
|
|
28
|
+
"site.run()",
|
|
29
|
+
"site.start()",
|
|
30
|
+
"site.listen()",
|
|
31
|
+
"site.close(wait)",
|
|
32
|
+
"site.reset()",
|
|
33
|
+
"site.require(filePath)",
|
|
34
|
+
"site.cmd(command, callback)"
|
|
35
|
+
],
|
|
36
|
+
"routing": [
|
|
37
|
+
"site.onREQUEST(method, route, callback)",
|
|
38
|
+
"site.onGET(route, callback)",
|
|
39
|
+
"site.get(route, callback)",
|
|
40
|
+
"site.onPOST(route, callback)",
|
|
41
|
+
"site.post(route, callback)",
|
|
42
|
+
"site.onPUT(route, callback)",
|
|
43
|
+
"site.put(route, callback)",
|
|
44
|
+
"site.onDELETE(route, callback)",
|
|
45
|
+
"site.delete(route, callback)",
|
|
46
|
+
"site.onALL(route, callback)",
|
|
47
|
+
"site.all(route, callback)",
|
|
48
|
+
"site.callRoute(name, req, res)",
|
|
49
|
+
"site.off(routeOrPath)"
|
|
50
|
+
],
|
|
51
|
+
"extraHttpMethods": [
|
|
52
|
+
"site.onTEST(route, callback)",
|
|
53
|
+
"site.onVIEW(route, callback)",
|
|
54
|
+
"site.onOPTIONS(route, callback)",
|
|
55
|
+
"site.onPATCH(route, callback)",
|
|
56
|
+
"site.onCOPY(route, callback)",
|
|
57
|
+
"site.onHEAD(route, callback)",
|
|
58
|
+
"site.onLINK(route, callback)",
|
|
59
|
+
"site.onUNLINK(route, callback)",
|
|
60
|
+
"site.onPURGE(route, callback)",
|
|
61
|
+
"site.onLOCK(route, callback)",
|
|
62
|
+
"site.onUNLOCK(route, callback)",
|
|
63
|
+
"site.onPROPFIND(route, callback)"
|
|
64
|
+
],
|
|
65
|
+
"requestHelpers": [
|
|
66
|
+
"req.addFeature(name)",
|
|
67
|
+
"req.hasFeature(name)",
|
|
68
|
+
"req.removeFeature(name)",
|
|
69
|
+
"req.getUserFinger()",
|
|
70
|
+
"req.word(name)",
|
|
71
|
+
"req.cookie(name)",
|
|
72
|
+
"req.cookies(name)"
|
|
73
|
+
],
|
|
74
|
+
"responseHelpers": [
|
|
75
|
+
"res.set(name, value)",
|
|
76
|
+
"res.status(code)",
|
|
77
|
+
"res.error(code)",
|
|
78
|
+
"res.download(path, name)",
|
|
79
|
+
"res.render(file, data, options)",
|
|
80
|
+
"res.html(file, data, options)",
|
|
81
|
+
"res.txt(name, data)",
|
|
82
|
+
"res.css(name, data)",
|
|
83
|
+
"res.js(name, data)",
|
|
84
|
+
"res.jsonFile(name, data)",
|
|
85
|
+
"res.send(content)",
|
|
86
|
+
"res.htmlContent(content)",
|
|
87
|
+
"res.textContent(text)",
|
|
88
|
+
"res.json(object, time)",
|
|
89
|
+
"res.redirect(url, code)",
|
|
90
|
+
"res.cookie(name, value)"
|
|
91
|
+
],
|
|
92
|
+
"files": [
|
|
93
|
+
"site.fileStat(path, callback)",
|
|
94
|
+
"site.fileStatSync(path)",
|
|
95
|
+
"site.css(name, callback)",
|
|
96
|
+
"site.xml(name, callback)",
|
|
97
|
+
"site.js(name, callback)",
|
|
98
|
+
"site.json(name, callback)",
|
|
99
|
+
"site.html(name, callback)",
|
|
100
|
+
"site.download(name, req, res)",
|
|
101
|
+
"site.downloadFile(path, req, res)",
|
|
102
|
+
"site.isFileExists(path, callback)",
|
|
103
|
+
"site.isFileExistsSync(path)",
|
|
104
|
+
"site.readFile(path, callback)",
|
|
105
|
+
"site.readFileRaw(path, callback)",
|
|
106
|
+
"site.readFileStream(path)",
|
|
107
|
+
"site.readFiles(paths, callback)",
|
|
108
|
+
"site.readFileSync(path)",
|
|
109
|
+
"site.writeFile(path, data, callback)",
|
|
110
|
+
"site.writeFileSync(path, data, encode, callback)",
|
|
111
|
+
"site.removeFile(path, callback)",
|
|
112
|
+
"site.deleteFile(path, callback)",
|
|
113
|
+
"site.createDir(path, callback)",
|
|
114
|
+
"site.mkDir(path, callback)"
|
|
115
|
+
],
|
|
116
|
+
"events": [
|
|
117
|
+
"site.on(name, callback)",
|
|
118
|
+
"site.call(name, args, callback)",
|
|
119
|
+
"site.quee(name, args, callback)",
|
|
120
|
+
"site.quee_check(name, fire)"
|
|
121
|
+
],
|
|
122
|
+
"features": [
|
|
123
|
+
"site.addFeature(name, value)",
|
|
124
|
+
"site.getFeature(name)",
|
|
125
|
+
"site.hasFeature(name)",
|
|
126
|
+
"site.feature(name, value)",
|
|
127
|
+
"site.addfeatures(path)"
|
|
128
|
+
],
|
|
129
|
+
"varsWordsMasterPages": [
|
|
130
|
+
"site.addVar(name, value)",
|
|
131
|
+
"site.getVar(name)",
|
|
132
|
+
"site.var(name, value)",
|
|
133
|
+
"site.addVars(path)",
|
|
134
|
+
"site.word(obj)",
|
|
135
|
+
"site.words.get(name)",
|
|
136
|
+
"site.words.add(word)",
|
|
137
|
+
"site.words.set(word)",
|
|
138
|
+
"site.words.addList(list)",
|
|
139
|
+
"site.words.addFile(path)",
|
|
140
|
+
"site.words.save()",
|
|
141
|
+
"site.addMasterPage(page)"
|
|
142
|
+
],
|
|
143
|
+
"apps": [
|
|
144
|
+
"site.addApp(app)",
|
|
145
|
+
"site.getApp(name)",
|
|
146
|
+
"site.connectApp(appOptions)",
|
|
147
|
+
"site.importApp(appPath, name2)",
|
|
148
|
+
"site.importApps(appDir)",
|
|
149
|
+
"site.loadApp(name, name2)",
|
|
150
|
+
"site.loadLocalApp(name, name2)"
|
|
151
|
+
],
|
|
152
|
+
"collection": [
|
|
153
|
+
"site.connectCollection(option, db)",
|
|
154
|
+
"collection.insertOne(doc, callback)",
|
|
155
|
+
"collection.insert(doc, callback)",
|
|
156
|
+
"collection.add(doc, callback)",
|
|
157
|
+
"collection.addOne(doc, callback)",
|
|
158
|
+
"collection.insertMany(docs, callback)",
|
|
159
|
+
"collection.addMany(docs, callback)",
|
|
160
|
+
"collection.insertAll(docs, callback)",
|
|
161
|
+
"collection.addAll(docs, callback)",
|
|
162
|
+
"collection.findOne(options, callback)",
|
|
163
|
+
"collection.find(options, callback)",
|
|
164
|
+
"collection.get(options, callback)",
|
|
165
|
+
"collection.select(options, callback)",
|
|
166
|
+
"collection.findMany(options, callback)",
|
|
167
|
+
"collection.findAll(options, callback)",
|
|
168
|
+
"collection.getAll(options, callback)",
|
|
169
|
+
"collection.selectMany(options, callback)",
|
|
170
|
+
"collection.updateOne(options, callback)",
|
|
171
|
+
"collection.update(options, callback)",
|
|
172
|
+
"collection.edit(options, callback)",
|
|
173
|
+
"collection.updateMany(options, callback)",
|
|
174
|
+
"collection.updateAll(options, callback)",
|
|
175
|
+
"collection.deleteOne(options, callback)",
|
|
176
|
+
"collection.delete(options, callback)",
|
|
177
|
+
"collection.remove(options, callback)",
|
|
178
|
+
"collection.deleteMany(options, callback)",
|
|
179
|
+
"collection.deleteAll(options, callback)",
|
|
180
|
+
"collection.count(options, callback)",
|
|
181
|
+
"collection.aggregate(pipeline, callback)",
|
|
182
|
+
"collection.createIndex(obj, options, callback)",
|
|
183
|
+
"collection.createUnique(obj, callback)",
|
|
184
|
+
"collection.import(filePath, callback)",
|
|
185
|
+
"collection.export(options, filePath, callback)"
|
|
186
|
+
],
|
|
187
|
+
"mongodb": [
|
|
188
|
+
"site.mongodb.ObjectID(id)",
|
|
189
|
+
"site.mongodb.connectDB(name, callback)",
|
|
190
|
+
"site.mongodb.connectCollection(options, callback)",
|
|
191
|
+
"site.mongodb.createIndex(options, callback)",
|
|
192
|
+
"site.mongodb.dropIndex(options, callback)",
|
|
193
|
+
"site.mongodb.aggregate(options, callback)",
|
|
194
|
+
"site.mongodb.dropCollection(options, callback)",
|
|
195
|
+
"site.mongodb.insertOne(options, callback)",
|
|
196
|
+
"site.mongodb.insertMany(options, callback)",
|
|
197
|
+
"site.mongodb.findOne(options, callback)",
|
|
198
|
+
"site.mongodb.findMany(options, callback)",
|
|
199
|
+
"site.mongodb.count(options, callback)",
|
|
200
|
+
"site.mongodb.distinct(options, callback)",
|
|
201
|
+
"site.mongodb.updateOne(options, callback)",
|
|
202
|
+
"site.mongodb.updateMany(options, callback)",
|
|
203
|
+
"site.mongodb.deleteOne(options, callback)",
|
|
204
|
+
"site.mongodb.deleteMany(options, callback)",
|
|
205
|
+
"site.backupDB(options, callback)",
|
|
206
|
+
"site.restoreDB(options, callback)"
|
|
207
|
+
],
|
|
208
|
+
"security": [
|
|
209
|
+
"site.security.addPermissions(list, callback)",
|
|
210
|
+
"site.security.addRole(role, callback)",
|
|
211
|
+
"site.security.updateRole(role, callback)",
|
|
212
|
+
"site.security.deleteRole(role, callback)",
|
|
213
|
+
"site.security.addRoles(list, callback)",
|
|
214
|
+
"site.security.getUsers(options, callback)",
|
|
215
|
+
"site.security.getUser(user, callback)",
|
|
216
|
+
"site.security.isUserExists(user, callback)",
|
|
217
|
+
"site.security.login(user, callback)",
|
|
218
|
+
"site.security.register(user, callback)",
|
|
219
|
+
"site.security.logout(req, res, callback)",
|
|
220
|
+
"site.security.addUser(user, callback)",
|
|
221
|
+
"site.security.updateUser(user, callback)",
|
|
222
|
+
"site.security.deleteUser(user, callback)",
|
|
223
|
+
"site.security.isUserLogin(req, res)",
|
|
224
|
+
"site.security.isUserHasPermission(req, res, permission)",
|
|
225
|
+
"site.security.isUserHasRole(req, res, role)"
|
|
226
|
+
],
|
|
227
|
+
"sessions": [
|
|
228
|
+
"site.getSession(req, callback)",
|
|
229
|
+
"site.saveSession(session)",
|
|
230
|
+
"site.sessions.attach(req, callback)",
|
|
231
|
+
"site.sessions.save(session)"
|
|
232
|
+
],
|
|
233
|
+
"websocket": [
|
|
234
|
+
"site.onWS(options, callback)",
|
|
235
|
+
"site.ws.start(options, callback)",
|
|
236
|
+
"site.ws.sendToAll(message)",
|
|
237
|
+
"site.ws.closeAll()",
|
|
238
|
+
"site.ws.wsSupport()"
|
|
239
|
+
],
|
|
240
|
+
"utilities": [
|
|
241
|
+
"site.copy(obj)",
|
|
242
|
+
"site.toNumber(value)",
|
|
243
|
+
"site.toInt(value)",
|
|
244
|
+
"site.toFloat(value)",
|
|
245
|
+
"site.toMoney(value, float)",
|
|
246
|
+
"site.random(min, max)",
|
|
247
|
+
"site.guid()",
|
|
248
|
+
"site.getRegExp(text, flag)",
|
|
249
|
+
"site.fetchURLContent(options, callback)",
|
|
250
|
+
"site.fetch(url, options)",
|
|
251
|
+
"site.request(url, options)",
|
|
252
|
+
"site.hide(data)",
|
|
253
|
+
"site.show(data)",
|
|
254
|
+
"site.removeRefObject(obj)",
|
|
255
|
+
"site.objectDiff(obj1, obj2)",
|
|
256
|
+
"site.toHtmlTable(obj)",
|
|
257
|
+
"site.typeof(value)",
|
|
258
|
+
"site.escapeRegExp(text)",
|
|
259
|
+
"site.getDate(value)",
|
|
260
|
+
"site.toDate(value)",
|
|
261
|
+
"site.toDateTime(value)",
|
|
262
|
+
"site.fromJson(data, defaultValue)",
|
|
263
|
+
"site.toJson(obj)",
|
|
264
|
+
"site.toBase64(data)",
|
|
265
|
+
"site.fromBase64(data)",
|
|
266
|
+
"site.to123(data)",
|
|
267
|
+
"site.from123(data)",
|
|
268
|
+
"site.getContentType(path)",
|
|
269
|
+
"site.getFileEncode(path)",
|
|
270
|
+
"site.md5(text)"
|
|
271
|
+
],
|
|
272
|
+
"integrations": [
|
|
273
|
+
"site.sendEmail(mail, callback)",
|
|
274
|
+
"site.sendMail(mail, callback)",
|
|
275
|
+
"site.sendFreeMail(mail, callback)",
|
|
276
|
+
"site.sendSmptMail(mail, callback)",
|
|
277
|
+
"site.checkMailConfig(mail, callback)",
|
|
278
|
+
"site.connectTelegramClient(session, apiId, apiHash, options)",
|
|
279
|
+
"site.telegramInit(token, onNewMessage, polling)",
|
|
280
|
+
"site.newTelegramBot(data, onNewMessage, polling)",
|
|
281
|
+
"site.sendTelegramMessage(token, chatID, message)",
|
|
282
|
+
"site.initFontKit(options, callback)",
|
|
283
|
+
"site.loadPDF(options, callback)",
|
|
284
|
+
"site.startProxy(options)",
|
|
285
|
+
"site.closeProxy(options)"
|
|
286
|
+
]
|
|
287
|
+
}
|
|
288
|
+
}
|