brpapa/recursion-tree-visualizer
์๊ฐ
๐ณ JavaScript, Python ๋๋ Go๋ก ์์ฑํ ์ฌ๊ท ํจ์์ ์์ค ์ฝ๋๋ฅผ ์ ๋ ฅํ๋ฉด ์ฌ๊ท ํธ๋ฆฌ๋ฅผ ์๊ฐํํ ์ ์์ต๋๋ค.
๋์์ธ ๋ฐ ๋ฏธ๋์ด์ธก์ ๋ ์คํ ์ฆ๊ฐ
- in 24h
- 0
- in 7 days
- -1
- in 15 days
- -2
- in 1 month
- ๊ธฐ๋ก ์์ง ์ค
์๋ก ๊ฒน์น๋ ๊ธฐ๊ฐ์ ์์ฆ๊ฐ๋์ด๋ฉฐ ์ผ๋ณ ํฉ๊ณ๊ฐ ์๋๋๋ค. ์ธก์ ๊ฐ์ด ์์ผ๋ฉด ๋น์ ๋ก๋๋ค. ์คํ๋ ๊ด์ฌ๋๋ฅผ ๋ํ๋ด๋ฉฐ ํ์ง์ ๋ณด์ฅํ์ง ์์ต๋๋ค.
README.md
OriginalRecursion Tree Visualizer
๐ฅ Winner project of the AlgoExpert SWE Project Contest ๐ฅ
Overview
Stop drawing recursion trees by hand. Watch the demo video or check out the live project.
Folders structure
web: react user interface.lambda: serverless lambda function to execute user-defined code remotely.
Local development
Web
In the web directory, run:
# to install all dependencies
$ npm install
# to run the app on http://localhost:3003
$ npm run start
Lambda
You can use the Amazon Runtime Interface Emulator (RIE), already contained in the docker image, to test the Lambda function.
In the lambda directory, run:
# build your local image
$ docker build --tag rtv .
# create and run a container using AWS RIE as executable to emulate a server for your lambda function
$ docker run --rm -p 8080:8080 rtv
# make a http request to your function, passing event with the -d in body field (escaped json), see examples in requests.http file
$ curl -XPOST "http://localhost:8080/2015-03-31/functions/function/invocations" -d '{"body":"{}"}'
Deploy to production
Lambda
In terraform folder:
- create terraform.tfvars file
- run
terraform init - run
terraform validate - run
terraform plan - run
terraform apply
Web
Ships web on Vercel, setup environment variables.
Acknowledgements
Thanks to Drawing Presentable Trees and Improving Walker's Algorithm to Run in Linear Time articles I implemented Reingold-Tilford's algorithm to position each node of the tree on a 2D plane in an aesthetically pleasing way.
Compatibility
For a better experience, I recommend using a chromium-based browser like Chrome or Edge.
Contact me
๊ด๋ จ ํ๋ก์ ํธ ์ดํด๋ณด๊ธฐ
๋ถ๋ฌ์ค๋ ์คโฆ