今日已更新 303 条资讯 | 累计 27107 条内容
关于我们

开发者

编程技术、框架工具、最佳实践

7586
篇文章

共 7586 篇 · 第 364/380 页

Reddit r/webdev

How to make dynamic svg images without having an image for every combination ?

I want to make a feature where my users would be able to customize a 2D svg character. They would choose their sex, their skin color, their clothes color, and maybe even put on accessories later. The arms of these characters would also change position. Obviously, I don't want to create an svg image for every possible combination, e.g. brown-man-red-shirt-pose1.svg white-woman-blue-shirt-pose1.svg, etc. If I did so I would have at least a hundred files to change each time I update the design of the characters which I don't wish on my worst enemy. So I would like a way to dynamically generate these combinations on the fly each time I render a character to the user. I asked a chatbot about it and it told me to treat my svg files the same way I treat my html templates with Django and render them using the render_to_string() function which allows me to pass variables for my template to display. I believe this way of doing it makes sense. For the different colors applied to the character, I would only need to add the following syntax: {{ shirt_color }} as the value of a path's "fill" in my svg and pass the value of the color in render_to_string() . However, if I want to attach the arms to the characters during render to not have a file for every arm pose there is with the same exact base character in each one, it becomes a bit more complicated. I would need to integrate a whole svg file inside of the first one and would need to care about its positioning and everything. I would also need to clean up the file each time I render it inside another svg file because of everything that comes with (<?xml version="1.0" encoding="UTF-8" standalone="no"?>, <!-- Created with Inkscape ( http://www.inkscape.org/ ) --> and the svg tag itself). So what is the most commonly agreed upon way of doing this? submitted by /u/Affectionate-Ad-7865 [link] [留言]

/u/Affectionate-Ad-7865 2026-05-29 03:48 👁 6 查看原文 →
Dev.to

Appendix: Live System Output

Appendix: Live System Output — Real Pipeline in Production All output below was captured live from the running pipeline on 2026-03-08. These are not mock outputs — they come from actual AWS infrastructure and Kubernetes clusters. ArgoCD — All 50 Applications Across 6 Clusters The following is the live output of argocd app list from the hub cluster ( myapp-production-use1 ). Every component of the pipeline is represented — security, logging, monitoring, backups, and the application itself. $ argocd app list --output wide NAME CLUSTER NAMESPACE PROJECT STATUS HEALTH argocd/argo-rollouts-myapp-production-use1 myapp-production-use1 argo-rollouts production Synced Healthy argocd/argo-rollouts-myapp-production-usw2 myapp-production-usw2 argo-rollouts production Synced Healthy argocd/aws-lbc-myapp-production-use1 myapp-production-use1 kube-system production Synced Healthy argocd/eso-myapp-production-use1 myapp-production-use1 external-secrets production OutOfSync Healthy ← known false positive argocd/eso-myapp-production-usw2 myapp-production-usw2 external-secrets production OutOfSync Healthy ← known false positive argocd/falco-myapp-dev-use1 myapp-dev-use1 falco production Synced Healthy argocd/falco-myapp-dev-usw2 myapp-dev-usw2 falco production Synced Healthy argocd/falco-myapp-production-use1 myapp-production-use1 falco production Synced Healthy argocd/falco-myapp-production-usw2 myapp-production-usw2 falco production Synced Healthy argocd/falco-myapp-staging-use1 myapp-staging-use1 falco production Synced Healthy argocd/falco-myapp-staging-usw2 myapp-staging-usw2 falco production Synced Healthy argocd/fluent-bit-myapp-dev-use1 myapp-dev-use1 logging production Synced Healthy argocd/fluent-bit-myapp-dev-usw2 myapp-dev-usw2 logging production Synced Healthy argocd/fluent-bit-myapp-production-use1 myapp-production-use1 logging production Synced Healthy argocd/fluent-bit-myapp-production-usw2 myapp-production-usw2 logging production Synced Healthy argocd/fluent-bit-myapp-

Matthew 2026-05-29 02:51 👁 9 查看原文 →
Dev.to

[Boost]

GPGPU.js: Run JavaScript on Your GPU With Zero Shader Knowledge Sven Herrmann Sven Herrmann Sven Herrmann Follow May 25 GPGPU.js: Run JavaScript on Your GPU With Zero Shader Knowledge # webgpu # javascript # typescript # performance Comments Add Comment 4 min read

Sven Herrmann 2026-05-29 02:37 👁 4 查看原文 →