-
1
Write registration routeTimes asked 2Official solution
SimpleLive Flask coding: chhota route likho, save, browser/curl se test. Syntax error terminal mein padho.
Example
@app.route('/ping') def ping(): return jsonify(ok=True) @app.route('/even/<int:n>') def even(n): return 'even' if n % 2 == 0 else 'odd'Community answers
No replies yet
No community answers yet
Open My solution to be the first to share yours.
My solution
Not submitted yet
-
2
Jwt and RBAC and show jwt stored areaTimes asked 2Official solution
SimpleRBAC = Role Based Access Control. Roles (admin/user) se permissions milti hain, har user pe alag list nahi.
Example
if current_user.role != 'admin': flash('Not allowed') return redirect(url_for('user.home'))Community answers
No replies yet
No community answers yet
Open My solution to be the first to share yours.
My solution
Not submitted yet
-
3
Why asynchronous and awaits are usedTimes asked 2Official solution
SimpleSync line pe ruk jao (2+2). Async I/O pe wait karte hue baaki kaam chalte (fetch, Celery).
JS async ≠ Celery async jobs. Context se bolo.
Why async jobs: slow/scheduled/bulk off request thread.
Pehle 1-line definition, phir related MAD2 layer (Vue SFC / Flask route / models.py / tasks.py / Redis).
4-line formula: input kahan se aaya, auth/validation kaunsa, DB ya cache ya Celery, kya return.
Related mix mat karo — cache ≠ Celery, authentication ≠ authorization, v-if ≠ v-show, Beat ≠ Worker. Follow-up ke liye ek difference ready rakho.
Project example: Login sync hash check fast. Email Celery async. Vue fetch async.
Community answers
No replies yet
No community answers yet
Open My solution to be the first to share yours.
My solution
Not submitted yet
-
4
How https works are they secureTimes asked 2Official solution
SimpleCode explain formula: input kya aaya → auth/validation → DB change → response/UI.
Viva tipFunction signature + 3-4 important lines + edge case.
Community answers
No replies yet
No community answers yet
Open My solution to be the first to share yours.
My solution
Not submitted yet
-
5
Vue lifecycle hooksTimes asked 4Official solution
SimpleLifecycle = component ki zindagi ke stages. API call tab jab DOM ready ho — mounted.
created: instance bani,
thisdata, DOM nahi. mounted/onMounted: page pe aa gaya — fetch, Chart.js, setInterval.
updated: data change ke baad. unmounted: cleanup (clearInterval) warna memory leak.Dashboards onMounted isliye: canvas/API tab valid. created mein $el nahi.
Composition: onMounted(() => {}) setup ke andar.
Example
export default { async mounted() { const r = await fetch('/api/venues') this.venues = await r.json() } }Project example: Venues.vue mounted fetch list. Clock component unmounted pe interval clear.
Viva tipcreated: data setup, DOM nahi. mounted/onMounted: $el mil gaya — fetch yahi. Dashboards isliye onMounted use karti hain.
Community answers
No replies yet
No community answers yet
Open My solution to be the first to share yours.
My solution
Not submitted yet