Comments (2)
@sderickson Since @smoratinos reorganized everything, do you still want to keep this open? I guess migrating to Koa would be cool, but we should probably do that soon if we're going to, or it's going to keep getting harder.
I would be uncomfortable switching to Restify, because we're going to want something that's going to be well-supported and around for a while.
from codecombat.
Yes, there's still some reorganization to do. I think we can forget about replacing Express with something else unless someone really wants to do that as a personal project. But there are still a couple major things that really bother me about the current server setup:
- There's no good way to see what the actual routes available are. This is because some of it's in Handler subclass logic, and the db.coffee file tries to do a bunch of magic with path inspection.
- The logic for routes and data need to be separated. That is, it's kind of set up right now as if everything that starts with /db/ is in the collection, but that may not be the case because of 'getByRelationship'.
Then the major steps to do are:
- Refactoring of Handler to put data-related logic into the Models (like formatEntity, or getEditableProperties).
- Create a routes file which defines all the urls and parameters, using the Router middleware in express.
Really, I'd need to spend some time poring over the express documentation and probably going over some examples of express server implementations to figure out a nicer, more logical structure, but this is what I'm thinking right now. The way it is now is still kind of wonky and unintuitive, I think.
from codecombat.
Related Issues (20)
- Sometimes no background music and no enemies appear. HOT 1
- I would like to translate all dynamic content into Japanese at once using ChatGPT. HOT 2
- Portuguese (Brazil) - English content in enemy-mine level HOT 2
- Virtual ISO with CodeCombat
- Sweep: fix comment whitespace issues in translate-utils.coffee HOT 3
- Sweep: fix comment whitespace issues in translate-utils.coffee HOT 7
- Javascript: String.match() no longer works. Including the Sample code given.
- How to start?
- Unable to send translated text. HOT 2
- Hi everyone ! i can't copy a new level from a existing level HOT 1
- Unhandled error: distance's argument target... but got null HOT 2
- Seek-and-Hide Collision failure when hero is Okar HOT 1
- Terkunci semua nya all organisasi pemilik HOT 1
- Delete data HOT 1
- Fix this 2
- I can't install using docker HOT 5
- Buttons with long labels
- Unhandled error: TypeError: Cannot read properties of undefined (reading 'attackDamage') HOT 1
- "The Wizard's Door" & "Deja Brew" - level bugs - Java
- Issues with display HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from codecombat.