???
- ??
- ????
- ?? ??
- API
- ?????
- ??? ?
- ?? ????
- ????
- ???
????: https://github.com/aelassas/bookcars
??: https://bookcars.dynv6.net:3002
??
? ????? ?? ?? ?? ??? ??? ? ?? ?? ??? ??? ?? ????? ??? ?? ???? ?? ???? ??????.
- UI/UX ??: ??? ??? ??? ?? ??? ?? ??? ??????
- ??? ??: ?? ??? ???? ?? ??? ???? ?? ? ??? ?? ??
- ??? DevOps: ???? ??? ????? ???? ?????? ??, ?? ? ????
- ???? ??: ??? ???? ?? ?? ?? ??? ??? ??? ?????
?? ??
?? ???? ? ?? ??? ??? ????.
- ??????
- Node.js
- ??DB
- ??
- ??
- ??? ????
- ???
- ?????
- ??
TypeScript? ??? ?? ??? ?? ??? ??? TypeScript? ????? ???????. TypeScript? ??? ???, ?? ? ??? ???? ??? ? ???? ?? ???, ???, ?? ?? ?? ??? ?? ??? ?????.
?? ??? ??? ??? ?? React? ????, ??? ??? ???? ?? MongoDB?, ??? ?? ??? ?? Stripe? ??????.
? ??? ???? ??? ????? ??? ?? ???? ?? ??? ??? ?? ?? ??? ???? ??? ????? ???? ??? ?? ??? ? ?? ??? ???? ????.
React? ??? ?? ??? ??? ?????.
- ???? ?? ????
- ??? UI? ??? ??? ?? ???? ?? ? ????
- ??? ?? ?? ???? ????? ?? ????
- ? ?? ?? ?? ? ??? ??
- ?? DOM ??
- React? ?? DOM? ??? ?? ????? ???????
- ??? ?? ??? ???? ??? ??? ?????
- ???? ???? ??
- ??? ???
- ?? ??? ?? ??? ??? ??? ?????
- ???? ??
- ??? ???? ?? ??? ????
- ??? ??? ??
- ???? ???? ?? ? ???
- ??? ??? ??
- JSX? ???? UI ?? ??? ?? ????? ?? ? ????
- ?? ??
- Meta(?? Facebook) ??
- ?? ????? ??
- ???? ??? ??
- ???
- ??? ? ??? ?????? ??? ??
- ?? ????? ????? ?? ??
- ??? ??? ?? ??(??????, ???, ??)
?? ??
? ????? ?????, ??? ???? ? ??? ?? ?? ???? ? ? ????.
?????
??????? ???? ?? ??? ??? ???? ??? ??? ? ??? ? ????.
??? ???? ??? ??? ??? ???? ?? ??? ??? ??? ? ?? ????? ?? ??????.
??? ???? ??? ? ?? ?? ???? ?? ?????.
??? ???? ?? ??? ???? ??? ? ?? ?? ??????. ???? ???? ?? ?? ??? ??? ??? ? ? ????. ?? ???? ?? ?? ???? ??? ?? ?? ? ??? ???? ?? ???.
??? ??? ??????. ?????? ?? ??? httpOnly, ??, ?? ? ??? sameSite???.???? ??? XSS, CSRF ? MITM ??? ?????.??? ??? ??? ????? ?? XST ??????? ?????.
??? ???? ??????.
??? ???? ?? ??? ???? ??? ? ?? ??????.
??? ???? ?? ??? ??? ? ? ?? ??????.
??? ?? ??????.
??? ??? ?? ??????.
??? ??? ??? ??? ???? ??? ? ?? ??????.
?? ???? ??? ?????? ?? ??????.
?? ????
????? ? ?? ??? ????.
- ???: ??? ????? ?? ?? ??? ??? ????. ?? ???? ? ? ????.
- ???: ??? ????? ?? ???? ???? ????. ?? ??? ??? ??? ? ????.
- ???: ?????? ??? ??? ???? ? ????. ??? ????? ???? ? ????.
? ???? ?? ????? ????? ???????. ? ????? ?? ?????? ?? ? ??? ??? ? ????. ???? ? ??? ?????? ??? ?? ????.
?? ?????? ???? ????, ???, ??, ??? ? ??? ???? ??? ? ????.
???? ? ????? ???? ?? ????? ?? ? ??? ??? ? ??? ?? ????? ???? ? ?? ?? ??? ?? ?? ???? ?? ???.
??? ??? ???? ??? ??????.
??? ???? ????? ??? ???? ??? ? ?? ??? ????? ???? ??????.
??? ????? ???? ??? ? ?? ??????.
??? ???? ????? ???? ??? ??? ???? ? ???? ?? ? ?? ??????. ??? ??? ??? ????? ?? ??? ??? 0?? ?????. ??? ?? ?? ?? ??? ????? ???? ???? ?? ???.
??? ???? ????? ???? ??? ? ?? ??????.
??? ???? ??? ???? ??? ? ?? ??????.
??? ?? ?? ??????.
?? ???? ??? ??? ????? ?? ??????.
API
API? ?? ????, ????? ? ??? ?? ??? ?? ??? ?????. API? MVC ??? ??? ????. ???? JWT? ?????. ??? ??, ??, ?? ?? ?? ? ??? ??? ??? ??, ???? ?? ???? ?? ? ?? ??? ?? ?? ? ??? ???? ?? ??? ????.
- ./api/src/models/ ???? MongoDB ??? ???? ????.
- ./api/src/routes/ ???? Express ??? ???? ????.
- ./api/src/controllers/ ???? ????? ???? ????.
- ./api/src/middlewares/ ???? ????? ???? ????.
- ./api/src/config/env.config.ts?? ?? ? TypeScript ?? ??? ???? ????.
- ./api/src/lang/ ???? ???? ???? ????.
- ./api/src/app.ts? ??? ???? ?? ?????.
- ./api/index.ts? API? ?? ??????.
index.ts? API? ?? ??????.
import 'dotenv/config' import process from 'node:process' import fs from 'node:fs/promises' import http from 'node:http' import https, { ServerOptions } from 'node:https' import * as env from './config/env.config' import * as databaseHelper from './common/databaseHelper' import app from './app' import * as logger from './common/logger' if ( await databaseHelper.connect(env.DB_URI, env.DB_SSL, env.DB_DEBUG) && await databaseHelper.initialize() ) { let server: http.Server | https.Server if (env.HTTPS) { https.globalAgent.maxSockets = Number.POSITIVE_INFINITY const privateKey = await fs.readFile(env.PRIVATE_KEY, 'utf8') const certificate = await fs.readFile(env.CERTIFICATE, 'utf8') const credentials: ServerOptions = { key: privateKey, cert: certificate } server = https.createServer(credentials, app) server.listen(env.PORT, () => { logger.info('HTTPS server is running on Port', env.PORT) }) } else { server = app.listen(env.PORT, () => { logger.info('HTTP server is running on Port', env.PORT) }) } const close = () => { logger.info('Gracefully stopping...') server.close(async () => { logger.info(`HTTP${env.HTTPS ? 'S' : ''} server closed`) await databaseHelper.close(true) logger.info('MongoDB connection closed') process.exit(0) }) } ['SIGINT', 'SIGTERM', 'SIGQUIT'].forEach((signal) => process.on(signal, close)) }
Node.js? Express? ???? ??? ???? TypeScript ?????. dotenv, process, fs, http, https, mongoose ? app? ??? ?? ??? ?????. ?? ?? HTTPS ?? ??? true? ???? ??? ????, ???? https ??? ??? ?? ? ? ???? ???? HTTPS ??? ?????. ??? ??? http ??? ???? HTTP ??? ?????. ??? PORT ?? ??? ??? ???? ?? ?????.
?? ??? ???? ??? ????? ????? ?? ??? ???? ????. ??? MongoDB ??? ?? ? ?? ?? 0?? ????? ?????. ????? ????? SIGINT, SIGTERM ?? SIGQUIT ??? ??? ? ??? ?? ??? ?????.
app.ts? API? ?? ??????.
import express from 'express' import compression from 'compression' import helmet from 'helmet' import nocache from 'nocache' import cookieParser from 'cookie-parser' import i18n from './lang/i18n' import * as env from './config/env.config' import cors from './middlewares/cors' import allowedMethods from './middlewares/allowedMethods' import supplierRoutes from './routes/supplierRoutes' import bookingRoutes from './routes/bookingRoutes' import locationRoutes from './routes/locationRoutes' import notificationRoutes from './routes/notificationRoutes' import carRoutes from './routes/carRoutes' import userRoutes from './routes/userRoutes' import stripeRoutes from './routes/stripeRoutes' import countryRoutes from './routes/countryRoutes' import * as helper from './common/helper' const app = express() app.use(helmet.contentSecurityPolicy()) app.use(helmet.dnsPrefetchControl()) app.use(helmet.crossOriginEmbedderPolicy()) app.use(helmet.frameguard()) app.use(helmet.hidePoweredBy()) app.use(helmet.hsts()) app.use(helmet.ieNoOpen()) app.use(helmet.noSniff()) app.use(helmet.permittedCrossDomainPolicies()) app.use(helmet.referrerPolicy()) app.use(helmet.xssFilter()) app.use(helmet.originAgentCluster()) app.use(helmet.crossOriginResourcePolicy({ policy: 'cross-origin' })) app.use(helmet.crossOriginOpenerPolicy()) app.use(nocache()) app.use(compression({ threshold: 0 })) app.use(express.urlencoded({ limit: '50mb', extended: true })) app.use(express.json({ limit: '50mb' })) app.use(cors()) app.options('*', cors()) app.use(cookieParser(env.COOKIE_SECRET)) app.use(allowedMethods) app.use('/', supplierRoutes) app.use('/', bookingRoutes) app.use('/', locationRoutes) app.use('/', notificationRoutes) app.use('/', carRoutes) app.use('/', userRoutes) app.use('/', stripeRoutes) app.use('/', countryRoutes) i18n.locale = env.DEFAULT_LANGUAGE await helper.mkdir(env.CDN_USERS) await helper.mkdir(env.CDN_TEMP_USERS) await helper.mkdir(env.CDN_CARS) await helper.mkdir(env.CDN_TEMP_CARS) await helper.mkdir(env.CDN_LOCATIONS) await helper.mkdir(env.CDN_TEMP_LOCATIONS) export default app
?? MongoDB ?? ???? ??? ?? MongoDB ??????? ??? ?????. ?? ?? Express ?? ??? cors, ??, ?? ? nocache? ?? ????? ?????. ?? ???? ?????? ???? ??? ?? ??? ??????. ?? ??? ??, ?? ??, ?? ??, ?? ??, ??? ??, ??? ?? ? ??????? ??? ??? ?? ??? ?? ??? ?????. ????? Express ??? ???? ?? ?????.
API?? 8?? ??? ????. ? ???? MVC ??? ??? SOLID ??? ??? ?? ????? ????. ?? ??? ??? ????.
- userRoutes: ???? ??? REST ??? ??
- supplierRoutes: ??? ?? REST ??? ??
- countryRoutes: ?? ?? REST ?? ??
- locationRoutes: ??? ??? REST ?? ??
- carRoutes: ??? ?? REST ?? ??
- bookingRoutes: ?? ?? REST ?? ??
- notificationRoutes: ?? ?? REST ?? ??
- stripeRoutes: Stripe ?? ????? ?? REST ??? ?????
? ??? ??? ????? ?????. ?? ?? countryRoutes? ???? ??? ??? ?????? ???????.
import express from 'express' import routeNames from '../config/countryRoutes.config' import authJwt from '../middlewares/authJwt' import * as countryController from '../controllers/countryController' const routes = express.Router() routes.route(routeNames.validate).post(authJwt.verifyToken, countryController.validate) routes.route(routeNames.create).post(authJwt.verifyToken, countryController.create) routes.route(routeNames.update).put(authJwt.verifyToken, countryController.update) routes.route(routeNames.delete).delete(authJwt.verifyToken, countryController.deleteCountry) routes.route(routeNames.getCountry).get(authJwt.verifyToken, countryController.getCountry) routes.route(routeNames.getCountries).get(authJwt.verifyToken, countryController.getCountries) routes.route(routeNames.getCountriesWithLocations).get(countryController.getCountriesWithLocations) routes.route(routeNames.checkCountry).get(authJwt.verifyToken, countryController.checkCountry) routes.route(routeNames.getCountryId).get(authJwt.verifyToken, countryController.getCountryId) export default routes
?? Express Router? ????. ?? ?? ??, ???, ???? ? ????? ???? ??? ?????.
routeNames?? countryRoutes ?? ??? ?????.
const routes = { validate: '/api/validate-country', create: '/api/create-country', update: '/api/update-country/:id', delete: '/api/delete-country/:id', getCountry: '/api/country/:id/:language', getCountries: '/api/countries/:page/:size/:language', getCountriesWithLocations: '/api/countries-with-locations/:language/:imageRequired/:minLocations', checkCountry: '/api/check-country/:id', getCountryId: '/api/country-id/:name/:language', } export default routes
countryController?? ??? ?? ?? ???? ??? ???? ????. ????? ?? ??? ? ?? ??? ?? ?? ??? ? ?? ??? ???? ?? ??? ?? ???????.
??? ??? ?????.
import { Schema, model } from 'mongoose' import * as env from '../config/env.config' const countrySchema = new Schema<env.Country>( { values: { type: [Schema.Types.ObjectId], ref: 'LocationValue', required: [true, "can't be blank"], validate: (value: any): boolean => Array.isArray(value), }, }, { timestamps: true, strict: true, collection: 'Country', }, ) const Country = model<env.Country>('Country', countrySchema) export default Country
??? env.Country TypeScript ?????:
export interface Country extends Document { values: Types.ObjectId[] name?: string }
???? ?? ?? ?? ????. ??? ???. ????? ??? ????? ?????.
??? LocationValue ?????:
import 'dotenv/config' import process from 'node:process' import fs from 'node:fs/promises' import http from 'node:http' import https, { ServerOptions } from 'node:https' import * as env from './config/env.config' import * as databaseHelper from './common/databaseHelper' import app from './app' import * as logger from './common/logger' if ( await databaseHelper.connect(env.DB_URI, env.DB_SSL, env.DB_DEBUG) && await databaseHelper.initialize() ) { let server: http.Server | https.Server if (env.HTTPS) { https.globalAgent.maxSockets = Number.POSITIVE_INFINITY const privateKey = await fs.readFile(env.PRIVATE_KEY, 'utf8') const certificate = await fs.readFile(env.CERTIFICATE, 'utf8') const credentials: ServerOptions = { key: privateKey, cert: certificate } server = https.createServer(credentials, app) server.listen(env.PORT, () => { logger.info('HTTPS server is running on Port', env.PORT) }) } else { server = app.listen(env.PORT, () => { logger.info('HTTP server is running on Port', env.PORT) }) } const close = () => { logger.info('Gracefully stopping...') server.close(async () => { logger.info(`HTTP${env.HTTPS ? 'S' : ''} server closed`) await databaseHelper.close(true) logger.info('MongoDB connection closed') process.exit(0) }) } ['SIGINT', 'SIGTERM', 'SIGQUIT'].forEach((signal) => process.on(signal, close)) }
??? env.LocationValue TypeScript ?????:
import express from 'express' import compression from 'compression' import helmet from 'helmet' import nocache from 'nocache' import cookieParser from 'cookie-parser' import i18n from './lang/i18n' import * as env from './config/env.config' import cors from './middlewares/cors' import allowedMethods from './middlewares/allowedMethods' import supplierRoutes from './routes/supplierRoutes' import bookingRoutes from './routes/bookingRoutes' import locationRoutes from './routes/locationRoutes' import notificationRoutes from './routes/notificationRoutes' import carRoutes from './routes/carRoutes' import userRoutes from './routes/userRoutes' import stripeRoutes from './routes/stripeRoutes' import countryRoutes from './routes/countryRoutes' import * as helper from './common/helper' const app = express() app.use(helmet.contentSecurityPolicy()) app.use(helmet.dnsPrefetchControl()) app.use(helmet.crossOriginEmbedderPolicy()) app.use(helmet.frameguard()) app.use(helmet.hidePoweredBy()) app.use(helmet.hsts()) app.use(helmet.ieNoOpen()) app.use(helmet.noSniff()) app.use(helmet.permittedCrossDomainPolicies()) app.use(helmet.referrerPolicy()) app.use(helmet.xssFilter()) app.use(helmet.originAgentCluster()) app.use(helmet.crossOriginResourcePolicy({ policy: 'cross-origin' })) app.use(helmet.crossOriginOpenerPolicy()) app.use(nocache()) app.use(compression({ threshold: 0 })) app.use(express.urlencoded({ limit: '50mb', extended: true })) app.use(express.json({ limit: '50mb' })) app.use(cors()) app.options('*', cors()) app.use(cookieParser(env.COOKIE_SECRET)) app.use(allowedMethods) app.use('/', supplierRoutes) app.use('/', bookingRoutes) app.use('/', locationRoutes) app.use('/', notificationRoutes) app.use('/', carRoutes) app.use('/', userRoutes) app.use('/', stripeRoutes) app.use('/', countryRoutes) i18n.locale = env.DEFAULT_LANGUAGE await helper.mkdir(env.CDN_USERS) await helper.mkdir(env.CDN_TEMP_USERS) await helper.mkdir(env.CDN_CARS) await helper.mkdir(env.CDN_TEMP_CARS) await helper.mkdir(env.CDN_LOCATIONS) await helper.mkdir(env.CDN_TEMP_LOCATIONS) export default app
LocationValue?? ?? ??(ISO 639-1)? ??? ?? ????.
??? ???? ?? ?????:
import express from 'express' import routeNames from '../config/countryRoutes.config' import authJwt from '../middlewares/authJwt' import * as countryController from '../controllers/countryController' const routes = express.Router() routes.route(routeNames.validate).post(authJwt.verifyToken, countryController.validate) routes.route(routeNames.create).post(authJwt.verifyToken, countryController.create) routes.route(routeNames.update).put(authJwt.verifyToken, countryController.update) routes.route(routeNames.delete).delete(authJwt.verifyToken, countryController.deleteCountry) routes.route(routeNames.getCountry).get(authJwt.verifyToken, countryController.getCountry) routes.route(routeNames.getCountries).get(authJwt.verifyToken, countryController.getCountries) routes.route(routeNames.getCountriesWithLocations).get(countryController.getCountriesWithLocations) routes.route(routeNames.checkCountry).get(authJwt.verifyToken, countryController.checkCountry) routes.route(routeNames.getCountryId).get(authJwt.verifyToken, countryController.getCountryId) export default routes
? ????? ?? ??? ???? ??? ??? ?(??? ??? ?)? ???? LocationValue? ?????. ????? ??? ?? ?? ?? ??? ?????.
?????
?????? Node.js, React, MUI ? TypeScript? ??? ? ?????????. ??? ??????? ??? ??? ??? ?? ?? ??? ??? ???? ??? ??? ? ??? ??? ? ????.
- ./frontend/src/assets/ ???? CSS? ???? ???? ????.
- ./frontend/src/pages/ ???? React ???? ???? ????.
- ./frontend/src/comComponents/ ???? React ?? ??? ???? ????.
- ./frontend/src/services/?? API ????? ???? ???? ????.
- ./frontend/src/App.tsx? ??? ??? ?? React ????.
- ./frontend/src/index.tsx? ?????? ?? ??????.
TypeScript ?? ??? ./packages/bookcars-types ???? ???? ????.
App.tsx? ?? ?? ????:
const routes = { validate: '/api/validate-country', create: '/api/create-country', update: '/api/update-country/:id', delete: '/api/delete-country/:id', getCountry: '/api/country/:id/:language', getCountries: '/api/countries/:page/:size/:language', getCountriesWithLocations: '/api/countries-with-locations/:language/:imageRequired/:minLocations', checkCountry: '/api/check-country/:id', getCountryId: '/api/country-id/:name/:language', } export default routes
? ??? ???? ?? React ?? ??? ???? ????.
?????? ? ???? ???? ??? ???? ????? ??? ? ???? ?? ? ????.
??? ?
? ???? Android ? iOS? ?? ??? ?? ?????. ??? ?? React Native, Expo ? TypeScript? ???????. ?????? ????? ??? ???? ??? ??? ??? ??? ?? ?? ??? ??? ???? ??? ??? ? ??? ??? ? ????.
????? ??? ?????? ??? ?? ??? ????. ?? ??? Node.js, Expo Server SDK ? Firebase? ???????.
- ./mobile/assets/ ???? ???? ???? ????.
- ./mobile/screens/ ???? ?? React Native ??? ???? ????.
- ./mobile/comComponents/ ???? React Native ?? ??? ???? ????.
- ./mobile/services/?? API ????? ???? ???? ????.
- ./mobile/App.tsx? ?? React Native ????.
TypeScript ?? ??? ?? ??? ???? ????.
- ./mobile/types/index.d.ts
- ./mobile/types/env.d.ts
- ./mobile/miscellaneous/bookcarsTypes.ts
./mobile/types/? ??? ?? ./mobile/tsconfig.json? ?????.
import { Schema, model } from 'mongoose' import * as env from '../config/env.config' const countrySchema = new Schema<env.Country>( { values: { type: [Schema.Types.ObjectId], ref: 'LocationValue', required: [true, "can't be blank"], validate: (value: any): boolean => Array.isArray(value), }, }, { timestamps: true, strict: true, collection: 'Country', }, ) const Country = model<env.Country>('Country', countrySchema) export default Country
App.tsx? React Native ?? ?? ??????.
'react-native-gesture-handler' ???? import React, { useCallback, useEffect, useRef, useState } from 'react' 'react-native-root-siblings'?? { RootSiblingParent } ???? '@react-navigation/native'?? { NavigationContainer, NavigationContainerRef }? ?????. 'expo-status-bar'?? { StatusBar? ExpoStatusBar? } ???? 'react-native-safe-area-context'?? { SafeAreaProvider } ???? 'react-native-paper'?? { ??? } ???? *? 'expo-splash-screen'?? SplashScreen?? ???? *? 'expo-notifications'?? ???? ???? '@stripe/stripe-react-native'?? { StripeProvider } ???? './comComponents/DrawerNavigator'?? DrawerNavigator ???? *? './common/helper'?? ???? ???? *? './services/NotificationService'?? NotificationService? ???? *? './services/UserService'?? UserService? ???? './context/GlobalContext'?? { GlobalProvider } ???? * './config/env.config'?? env? ???? ??.setNotificationHandler({ handlerNotification: async () => ({ shouldShowAlert: ??, shouldPlaySound: ??, shouldSetBadge: ??, }), }) // // ? ???? ?? ?? ?? ???? ??? ?? ???? ?? ?????. // SplashScreen.preventAutoHideAsync() .then((result) => console.log(`SplashScreen.preventAutoHideAsync() ??: ${result}`)) .catch(console.warn) // ??? ????? ???? ???? ?? ????. const ? = () => { const [appIsReady, setAppIsReady] = useState(false) const responseListener = useRef<Notifications.Subscription>() const NavigationRef = useRef<NavigationContainerRef<StackParams>>(null) useEffect(() => { const ???? = ???() => { const LoggedIn = UserService.loggedIn()? ?????. if (loggedIn) { const currentUser = UserService.getCurrentUser()? ?????. if (??????._id) { helper.registerPushToken(currentUser._id)? ?????. } ? ?? { ???.??() } } } // // ?? ?? ?? ?? // ????() // // ? ???? ???? ??? ???? ??? ????? ??? ?????(?? ?????, ????? ?? ??? ? ??). // responseListener.current = ??.addNotificationResponseReceivedListener(async (??) => { ???? { if (navigationRef.current) { const { ??? } = response.notification.request.content if (data.booking) { if (data.user && data.notification) { ??Service.markAsRead(data.user, [data.notification])? ?????. } NavigationRef.current.navigate('??', { id: data.booking }) } ? ?? { NavigationRef.current.navigate('??', {}) } } } ?? (??) { helper.error(err, false) } }) ??() => { ??.??????(responseListener.current!) } }, []) setTimeout(() => { setAppIsReady(true) }, 500) const onReady = useCallback(async () => { if (appIsReady) { // // ???? ??? ?? ???? ?????! ??? ??? ???? // `setAppIsReady`, ??? ?? ???? ?? ? ??? ??? ? ????. // ?? ??? ???? ? ?? ??? ??????. ??? ??, // ?? ?? ?? ??? ?? ?? ?? ???? ??? ????. // ????? ??????. // SplashScreen.hideAsync()? ?????. } }, [appIsReady]) if (!appIsReady) { null? ?? } ?? ( <??? ???> <SafeAreaProvider> <???> <StripeProvider ?? ?? ?={env.STRIPE_PUBLISHABLE_KEY} MerchantIdentifier={env.STRIPE_MERCHANT_IDENTIFIER}> <RootSiblingParent> <NavigationContainer ref={navigationRef} onReady={onReady}> <??????> <p>??? ?? ??? ??? ???? ????, ???? ????? ??? ???? ?? ? ????.</p> <h2> ?? ???? </h2> <p>?? ????? Node.js, React, MUI ? TypeScript? ??? ? ?????????. ????? ???? ????, ???, ??, ?? ? ??? ???? ??? ? ????. ????? ??? ????? ???? ???? ????? ?? ? ??? ???? ?? ??? ????? ???? ?? ???.</p>
- ./backend/assets/ ???? CSS? ???? ???? ????.
- ./backend/pages/ ???? React ???? ???? ????.
- ./backend/comComponents/ ???? React ?? ??? ???? ????.
- ./backend/services/?? API ????? ???? ???? ????.
- ./backend/App.tsx? ??? ??? ?? React ????.
- ./backend/index.tsx? ?? ????? ?? ??????.
TypeScript ?? ??? ./packages/bookcars-types ???? ???? ????.
???? App.tsx? ?????? App.tsx? ??? ??? ????.
?? ????? ? ???? ???? ??? ???? ?? ??? ?? ? ???? ?? ? ????.
?? ??
React Native? Expo? ???? ??? ?? ???? ?? ?? ????. Expo? React Native? ??? ??? ??? ?? ???? ????.
???, ?????, ??? ??? ??? ??(TypeScript)? ???? ?? ?????.
TypeScript? ?? ???? ???? ?? ??? ??? ????. JavaScript? ?? ?? ??? ???? ?? ??? ???? ??? ? ???? ?? ???, ???, ?? ? ?? ??? ??? ??? ??? ? ????.
?????! ? ?? ???? ????? ????.
??
- ??
- ??
- ??(?? ???)
- (VPS) ??
-
?? ?(??)
- ?? ???
- SSL
- ????? ??
- ??? ? ??
-
?? ??????
- Windows, Linux ? macOS
- ??
- ???? ??
-
??? ? ??
- ????
- ??
- ?? ??
- ?? ??
- ? ?? ??
- ?? ??? ? ?? ??
- ??
? ??? ???? ????: ??? ?? ????? ??? ?? ???? ?? ??? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!

? AI ??

Undress AI Tool
??? ???? ??

Undresser.AI Undress
???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover
???? ?? ???? ??? AI ?????.

Clothoff.io
AI ? ???

Video Face Swap
??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

?? ??

??? ??

???++7.3.1
???? ?? ?? ?? ???

SublimeText3 ??? ??
??? ??, ???? ?? ????.

???? 13.0.1 ???
??? PHP ?? ?? ??

???? CS6
??? ? ?? ??

SublimeText3 Mac ??
? ??? ?? ?? ?????(SublimeText3)

Node.js?? HTTP ??? ???? ? ?? ???? ??? ????. 1. ?? ????? ????? ??? ??? ? ?? ????? ?? ?? ? https.get () ??? ?? ??? ??? ? ?? ????? ?? ??? ?????. 2.axios? ??? ???? ? ?? ??????. ??? ??? ??? ??? ??? ??? ???/???, ?? JSON ??, ???? ?? ?????. ??? ?? ??? ????? ?? ????. 3. ?? ??? ??? ??? ??? ???? ???? ??? ??? ???? ?????.

JavaScript ??? ??? ?? ?? ? ?? ???? ????. ?? ???? ???, ??, ??, ?, ???? ?? ? ??? ?????. ?? ????? ?? ?? ? ? ??? ????? ?? ??? ??? ????. ??, ?? ? ??? ?? ?? ??? ??? ??? ???? ??? ??? ???? ??? ?? ??? ????. ?? ? ????? ??? ???? ? ??? ? ??? TypeofNull? ??? ?????? ??? ? ????. ? ? ?? ??? ???? ?????? ????? ???? ??? ???? ? ??? ? ? ????.

?????, JavaScript ???! ?? ? JavaScript ??? ?? ?? ?????! ?? ?? ??? ??? ??? ? ????. Deno?? Oracle? ?? ??, ??? JavaScript ?? ??? ????, Google Chrome ???? ? ??? ??? ???? ?????. ?????! Deno Oracle? "JavaScript"??? ????? Oracle? ?? ??? ??? ??????. Node.js? Deno? ??? ? Ryan Dahl? ??? ?????? ???? ????? JavaScript? ??? ???? Oracle? ????? ???? ?????.

??? JavaScript?? ??? ??? ?????? ?? ???????. ?? ??, ?? ?? ? ??? ??? ?? ????? ????? ?????. 1. ?? ??? ??? ????? ???? ??. ()? ?? ??? ??? ?????. ?. ()? ?? ??? ?? ??? ??? ?? ? ? ????. 2. ?? ??? .catch ()? ???? ?? ??? ??? ?? ??? ??????, ??? ???? ???? ????? ??? ? ????. 3. Promise.all ()? ?? ????? (?? ?? ?? ? ??????? ??), Promise.Race () (? ?? ??? ?? ?) ? Promise.AllSettled () (?? ??? ???? ??)

Cacheapi? ?????? ?? ???? ??? ???? ???, ?? ??? ??? ?? ???? ? ??? ?? ? ???? ??? ??????. 1. ???? ????, ??? ??, ?? ?? ?? ???? ???? ??? ? ????. 2. ??? ?? ?? ??? ?? ? ? ????. 3. ?? ?? ?? ?? ?? ??? ??? ?? ?????. 4. ??? ???? ?? ?? ???? ?? ?? ?? ?? ?? ???? ?? ?? ??? ??? ? ????. 5. ?? ???? ??, ??? ??? ? ??? ??, ?? ??? ? ?? ???? ???? ???? ? ?? ?????. 6.?? ??? ?? ?? ?? ??, ???? ?? ? HTTP ?? ????? ?????? ???????.

JavaScript? ??? ??? ?? ??, ? ? ? ?? ???? ???? ??? ??? ?????. 1. ?? ??? ?? ??? ???? ??? ??? ??? ??? ?? WebAPI? ?????. 2. WebAPI? ??????? ??? ?? ? ? ??? ?? ??? (??? ?? ?? ???? ??)? ????. 3. ??? ??? ?? ??? ?? ??? ?????. ?? ??? ??? ????? ??? ??? ?? ? ???? ?????. 4. ???? ?? (? : Promise. 5. ??? ??? ???? ?? ???? ???? ?? ?? ?? ??? ????? ? ??????.

??? ??? ?? ???? ?? ??? ???? ?? ??? ??? ?? ??? ?? ??? ?????. 1. ??? ?? : ?? ??? ?? ? ? ???? ?? ??? ???? ??? ???? ??????. ?? ??, ??? ?? ? ? ?? ??? ?? ? ?? ??? ??????. 2. ??? ?? : ??? ???? ?? ?? ??? ?? ???? ????? ? ?? ?????? ???? ????? ? ?? ?? ??? true? ??????. 3. ?? ???? ?? ?? ??? ?? ??, ?? ??? ? ?? ???? ?????. 4. DOM ??? ???? ??, ?? ? ??? ? ??? ??? ?? ???? ?? ???? ?????.

JavaScript ???? ? ? ?? ??? ???? ??? ???? ?? ??? ????. 1. ??? ???? ??? ??, ??, ??? ?? ? ??? ??? ?? ? ? ????. 2. ?? ? findIndex? ?? ?? ?? ???? ?? ? ?????. 3. ??? ??? ????? ?? ?? ??? ???? ? ?????. 4. ??? ?? ? ? ??? ?? ??? ?????. 5. ???? ??? ?? ??? ??? ? ?? ?????????. ??? ??? ????? ???? ????? ????.
