WebSocket API using okx.com.
Programming in html attributes....😭
Refuse to put hyperscript on this list...
Follow this article to implement htmx validation: https://marcus-obst.de/blog/bootstrap-validation-with-htmx.
The original code is as follows:
// Source: https://gist.github.com/marcus-at-localhost/c9f0a34a2e19d666fd95f61f002ea516 htmx.defineExtension('bs-validation', { onEvent: function (name, evt, data) { …When running the command "RUN sed -i 's/http://deb.debian.org/http://mirrors.ustc.edu.cn/g' /etc/apt/sources.list" in the Dockerfile, if you encounter the error "/etc/apt/sources.list: No such file or directory," change "/etc/apt/sources.list" to "/etc/apt/sources.list.d/debian.sources."
For programmers in …
After using the command "service crond status" to check, the following information appears: "Cron: pam_unix (cron:session): session opened/closed for user root by (uid=0)".
This is because cron can run at …
In Chrome extension code, whenever you include the
<form><button>click</button></form>
tags in HTML and click any button within the form, even if the button type is set to "button" instead of …
A django gettext with python brace format, this is correct :
gettext('Welcome to {0} store!').format(store_name),
and this is wrong:
gettext('Welcome to {0} store!'.format(store_name))
While upgrading Django Channels from 3.x to 4.0, if you encounter issues with the WebSocket handshake process, one solution is to add "daphne" to the top of the INSTALLED_APPS list …
First time using Copilot to code, I need to keep my mind focused and not be distracted by it...
Reference: https://mp.weixin.qq.com/s/34lQ4vxtc5KBUIADFfz3Ow
https://jackyu.cn/tech/push-lets-encrypt-cert-to-aliyun-cdn/
https://www.dothedev.com/blog/django-admin-list_filter/
I tried to retrieve data using the BigIntegerField ID in Django, but the returned queryset was empty.
After trying several times, I found that all of the IDs became 6977919360329322000, …
家里一个连接信息板的小显示器是某宝上买的电子垃圾, 经常重启树莓派后显示“无信号”, 像碰运气一样拔插电源成功.
今天实在受不了, 网上查了下,
vim /boot/config.txt 里把 config_hdmi_boost = 前面的注释去掉, 重启, 搞定.
上一行的注释里写着门板大一样的一行说明: “uncomment to increase signal to HDMI, if you have interference, blanking, or no display”.
apt autoremove --purge
能放出不少个G.
打印Sql语句之, print(queryset.query)
发现Group by 条件不只是把category列进去了, 还把另外一个字段A也列了进去, 原来是是模型里用了字段A默认排序, 给自动加到这来了.
清空默认排序, 改成如下语句即可:
queryset = MyModel.objects.all().values('category').order_by().annotate(total_amount=Sum('amount'))看来要开始教Python了(主要是我对Scratch没兴趣), 另外弄一张卡把他的Raspberry Pi 400装个RetroPie弄成游戏机激发一下?
https://blog.cnscud.com/docker/2021/11/17/docker-buildx.html
关键命令:
docker buildx version docker buildx create --name mybuilder(or whatever name) docker buildx use mybuilder(or whatever name)docker buildx ls docker buildx build --platform linux/amd64,linux/arm64 -t dockerhub.domain.com/laonanblog:1.0 . …
打算开发一个小小的物联网JS SDK, 想想现在都是所谓的“现代JS框架当道", 琢磨着做成npm包
我艹添加一个依赖, node_modules里多出几十个文件夹...