Front-end necessary skills--about cross-domain (cross-origin) problems and solving cross-domain problems

What is cross-domain/cross-origin? What does cross-domain mean? What does cross-origin mean? It seems that I have only heard of cross-domain but not cross-origin. In fact, these two are the same thing The cross-domain problem refers to the problem that different sites cannot call each other using ajax. The essence of the cross-domain problem ...

Posted by irishmike2004 on Thu, 22 Dec 2022 23:18:10 +0300

You must know JavaFile

The File object represents a path, which can be the path of a file or the path of a folderThis path can exist or not exist File structure method nameillustratepublic File(String pathname)Create a file object based on the file pathpublic File(String parent,String child)Creates a file object from a parent pathname string and a child pathname st ...

Posted by Idri on Thu, 22 Dec 2022 08:47:18 +0300

19 JavaScript one-liners that will make you look like a pro

In today's article, I want to share with you 19 one-line JS tricks that can help us improve our work efficiency and at the same time, make us look more professional. Now, let's enter today's content, spend some time every day, and learn some JS knowledge. 1. Generate a random string We can use Math.random to generate a random ...

Posted by fj1200 on Sat, 17 Dec 2022 21:28:41 +0300

The table style set by the front-end rich text cannot display the solution

After we have edited the text in the rich text editor, post it to see why the content previewed by the editor is inconsistent with the content actually displayed after saving. This is because most editors have their own style attributes, and these style attributes are often not included when obtaining rich text content, which leads to the incon ...

Posted by Sphynx on Fri, 16 Dec 2022 20:48:08 +0300

timeout in Jasmine of JS learning

Recently, I was crashed by the asynchronous timeout in Jasmine. The specific problem is setTimeout, which sometimes causes the test case to time out, and sometimes does not wait for enough time. So I decided to study the usage of asynchronous timeout in Jasmine. First, look at the example given by the jasmine documentation: describe("long asy ...

Posted by shanksta13 on Mon, 12 Dec 2022 14:21:41 +0300

Dynamic Routing, Dynamic Sidebar Menu

Dynamically load the sidebar menu Data case: returned by the background json data, please click to jump to the last view of the article There are three ways to do this, each with its own drawbacks The first (not recommended) Register all routes and dynamically load according to the dynamic menu Disadvantages: Insecure, users can change the b ...

Posted by bing_crosby on Sat, 03 Dec 2022 15:57:51 +0300

Mobile terminal adaptation scheme

Table of contents 1.rem adaptation 1.1 rem unit 1.2 Media Queries (to understand) 1.3 flexible.js 2 LESS 2.1 less operation 2.2 less nesting 2.3 less variables summary Mobile terminal adaptation scheme: flex + rem unit for adaptation effect (such as Taobao and Xiaomi mobile terminal) The current market is the most flex + view ...

Posted by ezbie on Mon, 14 Nov 2022 00:07:17 +0300

Vue uses Google Map

1. Prerequisites for use 1. Google developer account 2. The account should be bound with a debit card for subsequent api charges (it seems that mainland debit cards are not supported) 2. Add new projects and add referenced API s 3. Create a credential in the credential and get the key of the api Fourth, vue installation dependencie ...

Posted by cdm2 on Sat, 22 Oct 2022 05:27:24 +0300

The global scope and this point to

[Global scope] Objects that can be accessed anywhere in the code have global scope (that is, variables defined in the global scope can be used anywhere.) The global scope is created when the page is opened and destroyed when the page is closed. [Case 1: All undefined direct assignment variables are automatically declared as having global scop ...

Posted by khushbush on Thu, 13 Oct 2022 00:31:18 +0300

Silicon Valley Classroom 15_Live broadcast management module and WeChat sharing

Day 15 of Silicon Valley Classroom - Live Streaming Management Module and WeChat Sharing 1. Background system - live broadcast management module 1. Front-end integration of live course management 1.1, service_vod add method (1) CourseController add method @GetMapping("findAll") public Result findAll() { List<Course> list = co ...

Posted by jaydeesmalls on Wed, 12 Oct 2022 10:58:08 +0300