-
-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
83 changed files
with
3,300 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,5 +6,8 @@ | |
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": "explicit" | ||
}, | ||
}, | ||
"[mdx]": { | ||
"editor.wordWrap": "on" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
.next | ||
node_modules/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
node_modules |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
{ | ||
"editor.tabSize": 2, | ||
"[typescript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": true | ||
}, | ||
}, | ||
"[typescriptreact]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": true | ||
}, | ||
}, | ||
"[javascript]": { | ||
"editor.defaultFormatter": "esbenp.prettier-vscode", | ||
"editor.formatOnSave": true, | ||
"editor.codeActionsOnSave": { | ||
"source.fixAll.eslint": true | ||
}, | ||
}, | ||
"[mdx]": { | ||
"editor.wordWrap": "on" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
const cp = require("child_process"); | ||
const deploy = require("gh-pages"); | ||
|
||
cp.execSync("npm run build", { stdio: "inherit" }); | ||
|
||
deploy.publish( | ||
"out", | ||
{ | ||
branch: "gh-pages", | ||
dotfiles: true, | ||
}, | ||
(err) => { | ||
if (err) { | ||
console.log(err); | ||
process.exit(-1); | ||
} else clear(); | ||
}, | ||
); |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
/// <reference types="next" /> | ||
/// <reference types="next/image-types/global" /> | ||
|
||
// NOTE: This file should not be edited | ||
// see https://nextjs.org/docs/basic-features/typescript for more information. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
/** @type {import('next-sitemap').IConfig} */ | ||
module.exports = { | ||
siteUrl: 'https://typia.io', | ||
generateRobotsTxt: true, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
const withNextra = require("nextra")({ | ||
theme: "nextra-theme-docs", | ||
themeConfig: "./theme.config.tsx", | ||
}); | ||
|
||
/** @type {import('next').NextConfig} */ | ||
const config = { | ||
...withNextra(), | ||
exportTrailingSlash: true, | ||
images: { | ||
unoptimized: true, | ||
}, | ||
rewrites: async () => [ | ||
{ | ||
source: "/api", | ||
destination: "/api/index.html", | ||
}, | ||
], | ||
}; | ||
module.exports = config; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
{ | ||
"name": "typia.io", | ||
"version": "0.1.0", | ||
"description": "Typia Guide Documents", | ||
"private": true, | ||
"scripts": { | ||
"build": "rimraf .next && rimraf out && typedoc && next build && next export && next-sitemap", | ||
"deploy": "node build/deploy", | ||
"dev": "next dev", | ||
"prepare": "typedoc" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/samchon/typia" | ||
}, | ||
"author": "Jeongho Nam", | ||
"license": "MIT", | ||
"bugs": { | ||
"url": "https://github.com/samchon/typia/issues" | ||
}, | ||
"dependencies": { | ||
"@emotion/react": "^11.10.6", | ||
"@emotion/styled": "^11.10.6", | ||
"@monaco-editor/react": "^4.5.1", | ||
"@mui/icons-material": "^5.15.4", | ||
"@mui/material": "^5.12.0", | ||
"@rollup/browser": "^4.13.0", | ||
"lz-string": "^1.5.0", | ||
"monaco-editor": "^0.39.0", | ||
"next": "^13.0.6", | ||
"nextra": "latest", | ||
"nextra-theme-docs": "latest", | ||
"path": "^0.12.7", | ||
"prettier": "^3.2.5", | ||
"react": "^18.2.0", | ||
"react-dom": "^18.2.0", | ||
"tgrid": "^0.10.2", | ||
"tstl": "^3.0.0", | ||
"typescript": "^5.4.5", | ||
"typia": "^6.0.3" | ||
}, | ||
"devDependencies": { | ||
"@trivago/prettier-plugin-sort-imports": "^4.3.0", | ||
"@types/node": "^18.11.10", | ||
"@types/prettier": "^3.0.0", | ||
"@types/react": "^18.0.35", | ||
"gh-pages": "^5.0.0", | ||
"next-sitemap": "^4.0.7", | ||
"process": "^0.11.10", | ||
"rimraf": "^5.0.0", | ||
"ts-loader": "^9.5.1", | ||
"ts-node": "^10.9.1", | ||
"typedoc": "^0.25.13", | ||
"webpack": "^5.90.3", | ||
"webpack-cli": "^5.1.4", | ||
"write-file-webpack-plugin": "^4.5.1" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import Script from "next/script"; | ||
|
||
export default function Nextra({ Component, pageProps }) { | ||
const getLayout = Component.getLayout || ((page) => page); | ||
return ( | ||
<> | ||
<Script | ||
type="text/javascript" | ||
dangerouslySetInnerHTML={{ | ||
__html: ` | ||
(function(c,l,a,r,i,t,y){ | ||
c[a]=c[a]||function(){(c[a].q=c[a].q||[]).push(arguments)}; | ||
t=l.createElement(r);t.async=1;t.src="https://www.clarity.ms/tag/"+i; | ||
y=l.getElementsByTagName(r)[0];y.parentNode.insertBefore(t,y); | ||
})(window, document, "clarity", "script", "gqhymojzmp"); | ||
`, | ||
}} | ||
/> | ||
{getLayout(<Component {...pageProps} />)} | ||
</> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{ | ||
"index": { | ||
"title": "Introduction", | ||
"type": "page", | ||
"hidden": true, | ||
"display": "hidden", | ||
"theme": { | ||
"layout": "full" | ||
} | ||
}, | ||
"docs": { | ||
"title": "📖 Guide Documents", | ||
"type": "page" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"index": "🙋🏻♂️ Introduction", | ||
"setup": "📦 Setup", | ||
"-- tutorial": { | ||
"type": "separator", | ||
"title": "📖 Tutorial" | ||
}, | ||
"features": "Features", | ||
"examples": "Learn from Examples", | ||
"projects": "Learn from Projects", | ||
"-- appendix": { | ||
"type": "separator", | ||
"title": "🔗 Appendix" | ||
}, | ||
"api": { | ||
"title": "API Documents", | ||
"href": "/api", | ||
"newWindow": true | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"remote-function-call": "Remoteb Function Call", | ||
"remote-object-call": "Remote Object Call", | ||
"object-oriented-network": "Object Oriented Network", | ||
"nestjs": "NestJS WebSocket" | ||
} |
Empty file.
Empty file.
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"components": "Components", | ||
"worker": "Worker Protocol", | ||
"websocket": "WebSocket Protocol", | ||
"nestjs": "NestJS WebSocket" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
import { Tabs, Tab } from 'nextra-theme-docs' | ||
import Alert from '@mui/material/Alert'; | ||
import AlertTitle from '@mui/material/AlertTitle'; | ||
|
||
![Sequence Diagram](/images/diagrams/sequence.png) | ||
|
||
## Communicator | ||
Communicates with a remote system. | ||
|
||
`Communicator` is a class taking full responsibility to network communication with remote system. You can register a Provider, an object would be provided to the remote system, to the `Communicator`. Also, [Driver](#driver)\<[Listener](#listener)\>, which can access to the remote system's [Provider](#provider), is created by this `Communicator`. | ||
|
||
For reference, actual `Communicator` is the top-level abstract class, and all the classes responsible for network communication in `TGrid` are inheriting from this `Communicator` class. Here is the list of every communicator classes in `TGrid`. | ||
|
||
- [WebSocketConnector](./websocket#websocketconnector) | ||
- [WebSocketAcceptor](./websocket#websocketacceptor) | ||
- [SharedWorkerAcceptor](./worker#sharedworkeracceptor) | ||
- [SharedWorkerConnector](./worker#sharedworkerconnector) | ||
- [WorkerConnector](./worker#workerconnector) | ||
- [WorkerServer](./worker#workerserver) | ||
|
||
|
||
|
||
|
||
## Provider | ||
Object provided for remote system. | ||
|
||
`Provider` is an object provided for the remote system. | ||
|
||
The remote system can call the `Provider`'s functions through [Driver](#driver)\<[Listener](#listener)\>. | ||
|
||
|
||
|
||
|
||
## Listener | ||
Interface of the remote system's [Provider](#provider). | ||
|
||
`Listener` is a type definition (interface is recommended) of the remote system's [Provider](#provider). If you wrap the `Listener` type into the [Driver](#driver)\<`Listener`\> through `Communicator.getDriver<Listener>()` method, you can call the functions of the remote system's [Provider](#provider) asynchronously. | ||
|
||
For reference, it is possible to using the original [Provider](#provider) type of the remote system, so that composing [Driver](#driver)\<[Provider](#provider)\> type. However, such way is not recommended due to the dependency problem. Instead, consider to defining the [Provider](#provider) class to implement the `Listener` interface type. | ||
|
||
|
||
|
||
|
||
## Driver | ||
Driver of Listener for RPC (Remote Procedure Call). | ||
|
||
`Driver` is a proxy instance designed to call functions of the remote system. It has a generic argument [Listener](#listener) which means the type of remote system's [Provider](#provider), and you can remotely call the functions of the [Listener](#listener) asynchronously through the `Drive<Listener>` instance. | ||
|
||
When you call some function of [Listener](#listener) by the `Driver<Listener>` instance, it hooks the function call expression, and delivers the function name and arguments to the remote system through the [Communicator](#communicator). When the remote system replies the result of the function call, [Communicator](#communicator) `Driver<Listener>` resolves the promise of the function call expression with the result. |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
## WebSocketServer | ||
|
||
## WebSocketAcceptor | ||
|
||
## WebSocketConnector |
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"chat": "Chat Application", | ||
"market": "Grid Market" | ||
} |
Empty file.
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
module.exports = { | ||
printWidth: 80, | ||
semi: true, | ||
tabWidth: 2, | ||
trailingComma: "all", | ||
importOrder: ["<THIRD_PARTY_MODULES>", "^[./]"], | ||
importOrderSeparation: true, | ||
importOrderSortSpecifiers: true, | ||
// importOrderParserPlugins: ["decorators-legacy", "typescript", "jsx"], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
TypeDoc added this file to prevent GitHub Pages from using Jekyll. You can turn off this behavior by setting the `githubPages` option to false. |
Oops, something went wrong.