robert-meetup's Issues
Integrazione con OpenZeppelin Defender Relay per deploy Smart Contract
Come Admin
Quando aggiungo un nuovo Meetup
Devo deployare il corrispettivo smart contract per permettere agli utenti di interagire con Commenti e Like.
https://docs.openzeppelin.com/defender/relay
Bloccato da Open-Meetup/smart-contracts#2
Aggiungere autenticazione all'api di aggiunta del meetup
Come "amministratore"
Quando uno o più organizzatori richiedono la creazione di un meetup
Voglio poter aggiungere un nuovo meetup.
Questo flusso per ora sarà manuale, poi potrà essere automatizzato in un secondo momento per dare la possibilità agli organizzatori di creare i propri meetup magari pagando una minima fee per il costo di upload su Arweave... da capire.
In questa fase può essere anche una cosa molto semplice con un middleware di Express che controlla un bearer preimpostato.
Pseudocodice:
export const isAuthorized = (req, res, next) => {
if(req.headers.authorization === "Bearer ciccopasticcio")
next()
else
res.status(401).send("Suka!)
@hpatoio Che dici?
Deploy in ambiente di test
Add Jest for testing
configurare eslint e aggiungerlo al repo.
Configurare eslint e aggiungerlo al repo.
Ipotesi flusso di creazione Community
Gestione risposte asincrone
Ciao @hpatoio, sto cercando di mettere su un sistema per gestire le risposte asincrone con delle code.
Puoi buttare un occhio a questo e dirmi se ti torna l'approccio? Thx
const organizationsQueue = new Queue(
"organizations-queue",
"redis://localhost:6379" // require redis running
);
const wait = () =>
new Promise((res) => {
setTimeout(res, 10000);
});
organizationsQueue.process(async (job, done) => {
console.log("processing...");
await wait();
// deploy organization smart contract via Defender
// deploy arweave document
console.log("done");
done(null, {
id: "1234", // arweave hash
});
});
export const add = async (req: Request, res: Response) => {
console.log("New job...");
const job = await organizationsQueue.add({});
console.log("New job...created");
return res.status(200).json({
jobId: job.id,
});
};
export const getStatus = async (req: Request, res: Response) => {
const job = await organizationsQueue.getJob(req.params.id);
const status = await job?.getState();
return res.json({
status,
data: job?.returnvalue, // arweave hash for getter
});
};
Validazione POST
Va previsto un sistema di validazione dei dati che riceviamo via POST.
@hpatoio ho trovato questo e mi sembra una soluzione pulita, che dici? (usato come middleware come nell'esempio qui sotto)
https://express-validator.github.io/docs/running-imperatively.html
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.