inewlegend / appbasis
dev-master
2020-11-28 10:09 UTC
Requires
- bjeavons/zxcvbn-php: @stable
- cboden/ratchet: @stable
- clue/block-react: @stable
- monolog/monolog: @stable
- react/event-loop: @stable
- react/http: @stable
- react/http-client: @stable
- react/mysql: @stable
- react/promise-timer: @stable
- react/socket: @stable
This package is auto-updated.
Last update: 2025-03-28 19:25:36 UTC
README
-
backend - ReactPHP Modular server base
- configs, controllers, guards, models, modules, library, friends
- core -> main functionality
- configs -> config
- controllers -> controller logic
- guards -> secure controllers when they need extra conditioning
- models -> handle database queries
- library -> extra functions
- services -> .
- friends -> server engine
- ext -> plugins
-
frontend(s)
- Simple Angular, React base.
- Nice Api Structure
- WebSocket Support
Status
Backend: Development
Angular Frontend: Development
React Frontend: Not working yet.
Road Map
- todo
Goals
- Full async.
- Modular
- Well structured
- Readable
- Multi Engine Support
- Front-end(s): Angular, React
Demo
http://138.201.155.5/leo123/dist
Video:
Backend:
Frontend:
Install
$ git clone https://github.com/iNewLegend/AppBasis.git
Backend
$ mysql $ > create database appbasis $ > quit $ mysql < appbasis.sql $ cd appbasis $ composer update $ php appbasis.php server
Frontend
$ cd frontend/angular
$ ng serve
TODO
Backend:
- add: log to file with rotate.
- avoid: all core classes should not have direct creation of classes, you
auxiliary
instead. - think: add base class for all core classes
- check: captcha should be async.
- avoid: try to avoid as much as possible try and catch.
- add: unique email on database tbl: users
- issue: security when u have successfully login you delete all
bad
attempts - check-add: check at
controllers/welcome
methodupdates
- add method for async remote requests - add cache (check-if-good: https://github.com/reactphp/cache) - re-construct:
core/container
add methods - optimize: logger
- change: Config Service logs are not understand able.
- check: search for all
mixed
word in project, and be smart. - add: in database, to handle created_at and updated_at : - https://medium.com/@bengarvey/use-an-updated-at-column-in-your-mysql-table-and-make-it-update-automatically-6bf010873e6a
- add: security
wrk -t4 -c500 -d10s http://localhost:51190/authorization/login/czf.leo123@gmail.com/badpass
- change: at chat controller function hook is called by Core\Handler it should be an implantation
- add: document appbasis.php commands.
- add: database anti injection, using query parameters
Frontend:
Angular:
- logger should be better, its should better demonstrate client architecture
- handle in nice way, situation when server is offline
- reduce logic, html, css
React:
Everywhere:
- add switch for debug\production mode
- add mechanism of regeneration auth tokens
- add debug level
- send all backend log to frontend component
- each file should have @propose doc.
- add user access privileges admin panel for user editing blog editing / posting for editor
- add protocol documenation, usage exmaple
- add OAuth2 as plugin