<template> <div> <div style=”display:inline-block”> <canvas id=”myChartBar” width=”600″ height=”400″></canvas> </div> <div style=”display:inline-block”> <canvas id=”myChartLine” width=”600″ height=”400″></canvas> </div> <div> <canvas id=”myChartPie” width=”600″ height=”400″></canvas> </div> </div> </template> <script> import Chart from ‘chart.js/auto’ export default { name: ‘ChartDemo’, data () { return {} }, methods: { initChartBar () { var ctx = document.getElementById(“myChartBar”); new Chart(ctx, { type: ‘bar’, data: […]
Tag: using
Refactor Android asynchronous code using promises
Author: Wushan Old Demon Background Writing Android asynchronous tasks in business has always been a challenge. The previous callback and thread management methods were complex and cumbersome, making the code difficult to maintain and read. JavaScript actually faces the same problem in the front-end field, and Promise is one of its more mainstream solutions. Before […]
Build a website using wordpress based on IIS under Windows Server
Article directory Preface 1. Components required to build a website in WordPress 2. Component installation and configuration 1. Enable IIS 2. Install and configure php 3. Install and configure MySQL 4. Install and configure wordpress 3. Analysis of error prompts and causes encountered Foreword When I was learning wordpress before, because I was not familiar […]
Teach you step by step how to develop a map APP using COMPOSE~
Translated from: https://www.darrylbayliss.net/jetpack-compose-for-maps/ Foreword It’s hard to imagine that Jetpack Compose 1.0 was released back in July 2021. https://android-developers.googleblog.com/2021/07/jetpack-compose-announcement.html Now two years later, 24% of the top 1,000 apps on Google Play have adopted the new technology Compose, and its influence is evident. https://android-developers.googleblog.com/2023/05/whats-new-in-jetpack-compose.html As a member of the MAD (Modern Android Development) philosophy, Jetpack […]
Gopher hunting using hybrid search with Elasticsearch and Go
BY CARLY RICHMOND, LAURENT SAINT-FéLIX Like animals and programming languages, search has evolved through different practices, making it difficult to choose between them. In the final blog in this series, Carly Richmond and Laurent Saint-Félix combine keyword and vector searches to find gophers in Elasticsearch using the Go client. Building software today is a commitment […]
A redis3 master-3-slave cluster built based on hash slots using docker containers
1. Construction background Cluster mode-docker version, hash slot partition for billion-level data storage 1. 100-200 million pieces of data need to be cached. How to design it? Answer: Using distributed storage, there are generally three solutions in the industry The first type: hash remainder partition (generally used by small factories) Disadvantages: The biggest disadvantage of […]
Gorm project practice-using gen and defining relationships between tables
gorm project practice ER diagram Relationship arrangement One-to-one relationship: User and UserLog: One user corresponds to one user log, and a one-to-one relationship is established through the primary key of the User model and the foreign key of the UserLog model. One-to-many relationship: User and Teacher: One user can correspond to multiple teachers, through the […]
Various methods of positioning web page elements using Selenium!
To use Selenium to automate operations, the first thing to do is to open a URL link through the get() method of webdriver. After opening the link and completing the page loading, you can perform various operations on the page through the interface provided by Selenium. Let’s learn how to find elements. 3.1 Find and […]
Using eBPF to detect mmap leaks
Table of Contents background Official website malloc leak detection mmap leak detection Call munmap to release memory summary Background We know that the memory space requested by the mmap system call belongs to the file mapping area and the anonymous mapping area. This part of the area does not belong to the heap, so it […]
About using Android Service for the first time
First, understand what is service? My personal understanding of service is that it is an activity without an interface. It runs some events in the background of your mobile phone that do not need to be displayed to the user. For example: you have clearly exited the app, but some apps will still pop up […]