Skip to main content
Advanced Search
Search Terms
Content Type

Exact Matches
Tag Searches
Date Options
Updated after
Updated before
Created after
Created before

Search Results

211 total results found

Fetching base on input

React fetching the data

Mange API with state Now we will use state in react to help on manage with the API. with endpoint https://reqres.in/api/users we could get different response by passing parameter "page", so now we would use button to change the state and then use state on se...

Fundamental

Week1 : Backend introduction

What is Backend? The backend is the data and infrastructure that make your application work. ref: Backend Development: key languages, technologies, features in 2020 | DDI Development (ddi-dev.com) What is Backend Web development  Web development is based o...

JSON

Week1 : Backend introduction

What is JSON JSON stands for JavaScript Object Notation JSON is a text format for storing and transporting data JSON is "self-describing" and easy to understand JavaScript Object Notation (JSON) is a standard text-based format for representing structured d...

NodeJS Express

Week1 : Backend introduction

ExpressJS Express JS is a Node.js framework designed to build APIs that facilitate communication through HTTP requests and responses. One of the remarkable things about Express is that it gives developers complete control over the requests and responses that ...

Params & Body

Week1 : Backend introduction

new data.json {   "users": [     {       "id": 1,       "firstname": "Alice",       "balance": 1000,       "credit_ID": 2     },     {       "id": 2,       "firstname": "Bob",       "balance": 500,       "credit_ID": 1     },     {     ...

CSC105 Backend 27/4/23

CSC105 Backend fundamental

1. What is the Backend? Backend development (often called the “server-side” development), is the creation of everything that goes on behind the scenes of a website or application that the user can’t see. The backend normally consists of an application, server ...

Database connection

Week2 : Database connection

1. Let's start by creating an index.js then initializing your JavaScript project by running npm init in your terminal after that let's download the libraries that we will be using today which are express and mysql by running npm install express mysql2 dotenv...

Exercise & Assignment

Week1 : Backend introduction

1. Change Project Structure ref: Project structure for an Express REST API when there is no "standard way" – Corey Cleary Create directory name routers , controllersand services  Create a file in the router directory banks.js and users.js users.j...

Example of Read

Week2 : Database connection

Let's write the endpoint that query user balance data from the database and response to the user. This the schema of sample database 👇🏻 1. Let's create a first endpoint query balance from the database by create getBalance.js in controller->transactio...

Example of Create

Week2 : Database connection

1. Let's create an endpoint to create new user into the database, create create.js into directory controllers->users 2.  Write down using this code const connection = require("../../services/database"); const create = async (req, res) => { // Get data f...

Example of Update

Week2 : Database connection

Let's create an endpoint to update user balance into the database, create updateBalance.js into directory controllers->transactions 2.  Write down using this code const connection = require("../../services/database"); const updateBalance = async (re...

Example of Delete

Week2 : Database connection

Let's create an endpoint to delete user from the database, create deleteUser.js into directory controllers->users 2.  Write down using this code const connection = require("../../services/database"); const deleteUser = async (req, res) => { const ...

Assignment : Integration with frontend

Week2 : Database connection

1. Download the frontend from this link https://drive.google.com/file/d/1UuALet56_czOseatkx2-jCsgUwWiYFAO/view?usp=sharingthen run npm i when you run it should look like this then npm i axios 2.  Then go to your backend run npm i cors then add the code bel...

Sending Cookies

CSC105 - 2024: Backend Development Week... Cookies & JWT keys

What is Cookie? Cookies are small pieces of data stored on a user's device by websites they visit. They serve various purposes in web development. Example Cookies use cases. Session Management Personalization Tracking and Analytics Advert...

JWT: How to securely stores cookies.

CSC105 - 2024: Backend Development Week... Cookies & JWT keys

What is JWT? JWT stands for JSON Web Token. It's a compact, URL-safe means of representing claims to be transferred between two parties. The claims in a JWT are encoded as a JSON object that is used as the payload of a JSON Web Signature (JWS) structure or as...

Using Cookies

CSC105 - 2024: Backend Development Week... Cookies & JWT keys

How to use cookies Now as we can send cookies, I'll show you an example of how to get that cookies from user and use it. First let's create new file at /controllers/cookies name showCookies.js const ShowCookies = (req, res) => { const cookies = req.cook...

What is middleware?

CSC105 - 2024: Backend Development Week... Middlewares

What is middleware? middleware is a function that sits between the incoming request and the outgoing response in an application's request-response cycle. It intercepts and can modify the request and response objects, perform additional tasks, and pass control...

LAB: how to do auth in your app?

CSC105 - 2024: Backend Development Week... Authentication lab

Let's learn about authentication. Authentication is the one of the most common and widely use in almost all web applications. Authentication will be 2 methods mainly Register (Sign up) Login Let's start: Download this zip file and extract it in to ...

Create Repo

Hackathon Guide Initialization Group Pr...

1. Go to https://csgit.sit.kmutt.ac.th/ and look at the top right 2. Click the "+" Icon 3. Choose "New group" 4. fill in your group infomation Format Group Name  "CSHackXX" (XX mean number of your group e.i. 01,02,03,..,18) CSHackxx 5. Ad...

Initialization Project Front + Back

Hackathon Guide Initialization Group Pr...

1. Go to your IDE and open blank directory 2. open your own terminal write "git init" 3. Create a Directory "fronted" and "backend" 4. create init fronted react app (you use the framework that you want) (just guidelines don't need to follow al...