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

今日精选

HOT

最新资讯

共 29003 篇
第 167/1451 页
AI 资讯 Smashing Magazine

The Bull And Bear Case For Digital Design In The Age Of AI

As AI reshapes product design, it could give designers greater autonomy or expose the gaps that autonomy makes harder to hide. Exploring both the bull and bear cases, Andy Budd examines what happens when designers need less permission to act.

hello@smashingmagazine.com (Andy Budd) 2026-07-29 21:00 1 原文
AI 资讯 The Verge AI

DoorDash is going airborne with new drone delivery division

DoorDash is launching a new drone delivery program called DoorDash Air. The largest food delivery app in the US said that it has approval from the Federal Aviation Administration that clears the way for drone delivery in the near future. DoorDash said it has received a Part 135 air carrier certification from the FAA that […]

Andrew J. Hawkins 2026-07-29 21:00 12 原文
AI 资讯 Dev.to

Compilando Brainf*ck para a JVM, parte 1: o interpretador

Quando eu decidi aprender como a JVM funciona por dentro, eu precisava de uma linguagem simples o suficiente pra não atrapalhar o aprendizado. Algo onde eu pudesse focar na mecânica do compilador sem me perder na complexidade da linguagem fonte. Brainfuck foi a escolha óbvia. Esse é o primeiro post de uma série de três onde a gente vai construir, do zero, um compilador que transforma código Brainfuck em bytecode JVM executável. Sem dependências externas, sem framework, só Node.js puro. No final da série, você vai ter um compilador que gera arquivos .class válidos que rodam direto no java . O código completo está no GitHub . Nesse primeiro post, a gente vai construir o interpretador - que é a base pra tudo que vem depois. O que é Brainfuck Brainfuck é uma linguagem de programação esotérica criada em 1993 por Urban Müller. Ela tem 8 comandos . Oito. E ainda assim é Turing-completa - ou seja, em teoria, você pode computar qualquer coisa que qualquer outra linguagem computa. O modelo de execução é simples: Uma fita de memória com 30.000 células, cada uma armazenando um byte (0-255) Um ponteiro que aponta pra célula atual Entrada e saída (stdin/stdout) Os 8 comandos: Comando O que faz + Incrementa o valor da célula atual - Decrementa o valor da célula atual > Move o ponteiro uma célula pra direita < Move o ponteiro uma célula pra esquerda . Imprime o valor da célula atual como caractere ASCII , Lê um byte da entrada e armazena na célula atual [ Se a célula atual é zero, pula pro ] correspondente ] Se a célula atual não é zero, volta pro [ correspondente Qualquer outro caractere é ignorado - o que significa que você pode escrever comentários livremente no meio do código. Um exemplo simples Pra imprimir a letra "A" (código ASCII 65), você precisa colocar o valor 65 na célula e usar . : +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ . São 65 sinais de + seguidos de um . . Funciona, mas é feio. Uma forma mais elegante: ++++++++ [ > ++++++++ < - ] > +. O qu

Edy Silva 2026-07-29 20:52 11 原文
AI 资讯 Dev.to

3 Action Mailer Features I Didn't Know Existed

A few weeks ago I needed to check something in the Action Mailer docs, just a quick lookup. I ended up spending much more time there than expected and found a few features I had no idea existed, even though I've been using Action Mailer in production for a while. One of them lets you see an email before it's ever sent. Another lets you modify an email right before it goes out. And the third one allows you to override the default delivery options dynamically. I figured I probably wasn't the only one who had missed these, so here are three Action Mailer features that caught my attention. If you want to explore more, the official Action Mailer documentation is always a great place to start. 1. Previews Before I found this, testing an email meant sending it to myself, checking my inbox, tweaking the template, and repeating. Turns out ActionMailer has a built-in way to preview emails in the browser, without sending anything. You add a preview class in test/mailers/previews like: class InvitationMailerPreview < ActionMailer :: Preview def team_invitation InvitationMailer . with ( user: User . first , company: Company . first ). team_invitation end end And visit http://localhost:3000/rails/mailers/invitation_mailer/team_invitation . This removes the usual feedback loop of tweaking a template. You just refresh the browser instead. Rails also allows custom preview paths if you want to keep previews in a different location: config . action_mailer . preview_paths << " #{ Rails . root } /lib/mailer_previews" This was a small discovery, but it immediately improved my workflow. 2. Interceptors An interceptor is a hook that runs right before an email is handed off for delivery, letting you modify it. A common use case is preventing mistakes in staging environments. Nobody wants to accidentally send a real looking email from a staging application to an actual customer. Another common approach is redirecting all outgoing mail in staging or development environments to a single defaul

Pavel Myslik 2026-07-29 20:47 8 原文
开发者 Dev.to

KNX Motion-Sensor Automations in Home Assistant

A note before the post: the mistake in the first section is genuinely mine. It cost me an evening of forking conditions in Home Assistant before I accepted the fix didn't belong in Home Assistant at all. I've left it in rather than writing around it, because it's the part I'd have wanted to read first. The first time motion-controlled lighting actually worked in my place, it didn't feel clever. It felt obvious — I walked into a dark hallway and the light was already on by the time I'd registered it was dark. That's the bar. Not smart , just attentive. Getting there with seven KNX motion sensors took me less code than I expected and one insight I wish I'd had on day one. This is Part 05 of the series. The earlier parts cover the boring-but-load-bearing groundwork: running Home Assistant in Docker and wiring up HACS . Here I'm assuming HA is up, talking KNX, and you just want the lights to behave. One sensor, two jobs, two addresses Here's the mistake I made, and it's the whole reason this post exists. KNX exposes each motion sensor to Home Assistant as a binary_sensor with device_class: motion , fed by a KNX group-address state object you configure in knx.yaml with a state_address per sensor. Simple enough. So I wired all seven sensors with one group address each and pointed both the lighting automation and the presence logic at the same signal. That works right up until you want the two to behave differently. A light should react to the smallest twitch, instantly, generously. Presence and security want the opposite: a debounce, a grace window, some scepticism before they commit. When both ride the same group address, every change you make to one quietly deforms the other. I spent an evening forking conditions in Home Assistant trying to make one signal mean two things. The fix isn't in Home Assistant at all. It's in ETS: give each physical PIR a second group address . One drives comfort lighting, the other feeds presence and the alarm path. I use a flat convention —

Michael Bernhart 2026-07-29 20:46 10 原文