Tag:middleware

  • How to use Redux gracefully in react project

    Time:2021-4-17

    preface Maybe your current project has not reached the level of applying Redux, but it’s not bad to know in advance. This article will not let Amway use redux concept First of all, what frameworks and tools will we use? React UI framework Redux The state management tool has nothing to do with react, and […]

  • Using responsibility chain pattern to realize middleware function

    Time:2021-4-17

    In fact, middleware is nothing more than a filter. In the framework, requests or responses are filtered layer by layer. The most appropriate way to realize this function is the responsibility chain mode The realization of responsibility chain mode can be seen in this essayResponsibility chain mode   The following records how to implement the middleware […]

  • Laravel integrated picture captcha

    Time:2021-4-17

    1. Please refer to the project document for the installation / usage of the foundation github: https://github.com/mewebstudi… 2. API call interface http://localhost/captcha/api/mathMath can be replaced with the captcha type defined in the configuration fileThe interface returns JSON, mainly using two parameters key and imgKey needs simultaneous interpreting to the backstage for verification.IMG is a picture […]

  • Cross Site Request Forgery in Django CSRF

    Time:2021-4-14

    Cross Site Request Forgery in Django CSRF 1、 What is Cross Site Request Forgery Cross Site Request Forgery. English abbreviation: CSRF, English full name: Cross Site Request Forgery For example: phishing sites There is a fake website which is exactly the same as a bank. The user completes the transfer function on this page, and […]

  • Go Negroni

    Time:2021-4-14

    brief introduction negroniIs a library that focuses on HTTP middleware. It is small, non intrusive and encourages the use of standard librariesnet/httpProcessor for(Handler)。 This article introduces the library. Why middleware? There are some logic codes, such as statistics, logs, debugging, etc., which are needed in every processor. If you add them one by one, they […]

  • Sub database and sub table vs newsql database

    Time:2021-4-11

    Where is the advancedness of newsql database?Distributed transactionHa and multi live in different placesScale scaling and fragmentation mechanismDistributed SQL supportStorage engineMaturity and ecologySummary Recently, during the scientific and technological exchanges with peers, I was often asked how to choose the sub database, sub table and distributed database. There are many articles about middleware + traditional […]

  • New Year holiday these two days rolled a laravel starter, welcome to use and star

    Time:2021-4-10

    Take out the common functions in daily development and make a starter to avoid a lot of repetitive work when opening a new project. The repo will be maintained for a long time. Welcome to star. If there are bugs or experience problems in use, please ask issue. x1a0xv4n/laravel-starter: 😺 Your next laravel-api-starter in 30 […]

  • It’s really fragrant. We’ll make a redux

    Time:2021-4-9

    From college to nowReactIt’s been more than a year since it was developed. Although it’s still a rookie, it’s not easyreactAbuse me a thousand times, I still wait for her as first love. ReduxIt’s the first state manager I use. I always think it depends onreactYes, it isreact-reduxI’m confused. Understand the official website and access […]

  • Introducing jQuery into EJS

    Time:2021-4-9

    I use express+ Noode.js +EJS + mongodb built a project to put jQuery code into the JavaScript directory, but jQuery failed. I searched many methods on the Internet, such as NPM requirejs, jQuery and script tag failed. Finally, I found the real reason. In fact, the static resource access of express failed. The reason for […]

  • Asking for help – about the response of NETCORE 2.2 Middleware

    Time:2021-4-8

    Background: the API interface program is developed based on netcore2.2, and an exception capture middleware is defined to capture the unhandled exception and access to status code 404 and 500 (the starting point of the design is that when there is a non-200 response, I will process it to 200 and return the fixed format […]

  • React + Redux + react router

    Time:2021-4-3

    React ReactIs an abstraction layer of DOM rendering(View layer)React can not only deal with web pages through react DOM, but also be used in server-side SSR, mobile side react native and desktop side electron. Web development needs matchingReact-domuse import React from ‘react’; import ReactDOM from ‘react-dom’; const App = () => ( <div> <h1>Hello React</h1> […]

  • Cross domain issues in swoft Middleware

    Time:2021-4-3

    The demo of cross domain processing described in the official swoft2.0. X document is as follows:This method seems to have no problem under normal request, but if$handler->handle($request)If an exception occurs in the step, for example, the validator intercepts the illegal request parameter and throws a validatorexception, then the subsequent operation of adding the request header […]