node uses command line interaction to generate corresponding templates
Creation time: October 15, 2019
Test environment: win10 node-v10.16.1
Inspired by the Vue cli initialization project, I want to explore its principle and implement a similar method to create a common template block in the project.
There are three ways to achieve this
readline of node
Using process to implement
Third party package inquirer ...
Posted by ben2k8 on Wed, 16 Oct 2019 16:24:43 +0200
React.createRef()/forwardRef() for React source parsing
I. React.createRef()GitHub: https://github.com/AttackXiaoJinJin/reactExplain/blob/master/react16.8.6/packages/react/src/ReactCreateRef.js
Effect:Get the DOM instance of the target element
Use:
import React from 'react'
export default class Father extends React.Completed{
constructor(props){
super(props)
this.father=React.createRef( ...
Posted by iyia12co on Tue, 15 Oct 2019 21:59:11 +0200
Drag Data Loading by ReactHooks+ReactDnd
Drag to load API fields
Implement automatic loading of API by dragging a background API to Form with the mouse, so the fields become forms.Drag component uses react-dnd plug-in, data interaction and page updating are implemented by Hooks.Hooks Official Documents https://react.docschina.org/docs/hooks-intro.htmlReactDnd official document http:// ...
Posted by jrtaylor on Tue, 15 Oct 2019 09:16:11 +0200
Qt Writes Custom Control 69 - Line Number Statistics
I. Preface
Code line count is mainly used to count the number of code lines of all files in the project, including blank lines, comment lines, code lines. You can specify filter extensions, such as files that only want to count. cpp, you can also specify files or directories for statistics. The first thing to do after writing this tool is to co ...
Posted by cwetherbee on Mon, 14 Oct 2019 03:51:28 +0200
Spring Security OAuth2 Judges Dynamic Permissions Based on Request URI
GitHub address
Code cloud address
Usually we control permissions by @PreAuthorize("hasRole('ROLE_USER')) annotation, and configuring permission requirements in HttpSecurity. Here, we control access rights based on the requested URI, and we can use annotations to control access rights.
Create a new resource project to allocate resources and ...
Posted by bonekrusher on Sat, 12 Oct 2019 21:21:03 +0200
Spring 5 Source Parsing 7-Configuration Class Post Processor
Configuration ClassPostProcessor inherits the BeanDefinitionRegistryPostProcessor interface, which implements the postProcessBeanDefinitionRegistry and its parent BeanFactoryPostProcessor#postProcessBeanFactory method.
For an analysis of the postProcessBean Definition Registry method, see: Spring 5 Source Learning (5) Configuration Class Post P ...
Posted by mrbill501 on Thu, 10 Oct 2019 06:29:08 +0200
alpine mirror java log Chinese question mark garbled
0x00 Preface
I use alpine as the foundation mirror to build jdk8 image, and provide support for java micro service architecture of online business. However, if there is Chinese in the printed log of java services running in containers, there will be the following "?"?
Here's how to solve this problem, reprinted from this in github is ...
Posted by abx_2112 on Wed, 09 Oct 2019 23:45:44 +0200
Tamping Java Foundation Series 11: Deep Understanding of Callback Mechanisms in Java
Catalog
Calls between modules
Callback in multithreading
Java callback mechanism in practice
Example 1: Synchronized invocation
Example two: from shallow to deep
Example 3: Tom does the problem
Reference articles
Public address
Java Technology
Personal Public ...
Posted by fcaserio on Wed, 09 Oct 2019 16:37:59 +0200
How to use history mode for routing in vue multi-page project
Preface
Before writing a Vue project, we need to add a printed page. We need to use multi-page mode to develop it. It is easy for vue-cli3 to configure multi-page for initialized project. But we found that print.html can not configure the history mode routing, once using history mode routing. Writing a simple demo for help online did not solve ...
Posted by Qnuts on Tue, 08 Oct 2019 21:08:08 +0200
BeanPostProcessor, Initializing Bean, init-method Analysis of Spring
TIPS:Spring has actually provided us with some hook methods to do some post-processing business after initializing beans. The so-called post-processing is the Bean Post Processor in this article.
BeanPost Processor provides two callback methods in which you can implement some customized business logic.
...
Posted by mm00 on Tue, 08 Oct 2019 08:15:13 +0200