aft

Craft Holsters Introduces Exceptional Holster Selection for Ruger LCP Max: The Ideal Choice for Concealed Carry Enthusiasts

Secure Comfort Meets Style: Craft Holsters Unveils Premium Range for Ruger LCP Max - The Ultimate Concealed Carry Companion




aft

Pennsbury Manor Announces Brews & Bites Fundraiser June 24th Featuring Craft-Brewed Beers, Food Trucks, and Live Bands

Robust June Events Calendar Also Includes a Juneteenth Celebration, Colonial Camp, and Weekly Summer Sunday Events




aft

Craft Holsters Introduces Comprehensive Glock Guides for All Glock Enthusiasts

Craft Holsters Launches In-Depth Guides Explaining 34 Different Types of Glock Pistols




aft

Tarrant Events Center Can Host Your Craft Fair or Small Trade Show

The event center is the ultimate event venue for unforgettable trade expos & craft fairs in Haltom City, Texas.




aft

Affinity Nightlife's Post Television Awards After Party Celebrated with the Industry's Biggest Stars

Adam Glove's 'Dream in Gold' Gala was One of the Hottest Events in Hollywood with a Packed House




aft

Bitcoin Rally Cools After Jump of About 30% Since Trump Victory




aft

Why Were Dividend King Stocks Coca-Cola, PepsiCo, and Procter & Gamble Falling After the Election?




aft

Novavax stock plunges after quarterly earnings, but company sees hope in licensing deals




aft

11 stocks that are soaring after Trump's election win — and why they're up




aft

Thinking About Leaving The U.S. After Trump's Win? Here Are The Top Expat Destinations




aft

Reflecting on What Matters After a Terminal Cancer Diagnosis

How does someone who's been told he will die much sooner than expected find contentment in the time he has left? As a former therapist, cofounder of the Deeper Coaching Institute, and business book author, Mark Goulston has spent his entire career trying to help others manage their emotions, improve their communication, and find the right balance between the personal and the professional. Faced with his own cancer diagnosis, he's been reflecting on lessons learned in his own life, things he and clients wish they'd done differently, and how to both prepare for a "good" death and leave a meaningful legacy. He shares his newfound perspective and his advice for early, mid- and late-career leaders.




aft

Crafty Holiday Gift Idea | Duck Tape for Kids

Maria takes a look at a great crafty holiday gift idea for kids - Duck Tape!




aft

Fall Half Pumpkin Craft for a Fun DIY Door Project

Maria uses a half pumpkin to make a Fall door decoration!




aft

Press Release: Impact of first federally funded anti-smoking ad campaign remains strong after three years

More than 1.8 million smokers attempted to quit smoking and an estimated 104,000 Americans quit smoking for good because of the nine-week-long 2014 Tips From Former Smokers ( Tips ) campaign.





aft

Redfin CEO Apologizes to Shareholders After Profit Eludes Company in Q3 Earnings Report

2024’s third quarter dragged down Redfin’s financials, according to the company’s latest earnings report.  Redfin’s revenue declined to $278 million, down from $295 million during Q2 2024, but was up 3% year-over-year from Q3 2023’s $269 million. The company also saw a net loss of $33.8 million, a larger loss than $27.9 million in Q2…

The post Redfin CEO Apologizes to Shareholders After Profit Eludes Company in Q3 Earnings Report appeared first on RISMedia.




aft

Rededicating After an Upset

How many times have you gone into a vacation with the best of intentions, only to get derailed by temptation?  Or maybe you give yourself a vacation from healthful living while you’re away and intend to get right back on track afterward.  Did you know the average cruise passenger gains 7-10 lbs on a week […]



  • Health and Wellness

aft

Lead C# / Unity Programmer (REMOTE): Afterschool Studio

  Afterschool Studio is seeking a Lead C#/Unity Programmer to join our team and help us create art-forward, systems-driven games that allow for expressive player experiences. We’re a small tight-knit team building working on projects with strong aesthetics and compelling strategy elements. We’re looking for a team member who shares our vision - could it be you? This role will be primarily focused on helping to bring our flagship game Cantata to a 1.0 release, but will also have purview over other games in development at Afterschool.   Responsibilities   Guide the development process of large scale strategy games Design, implement and maintain core gameplay systems and features Maintain build stability by tracking, finding, and fixing some of the more difficult bugs that surface during development Profile and optimize critical systems, and guide other departments in creating optimal assets and content Scope and deliver regular updates to a game currently in Early Access   Requirements   Shipped 2+ retail game titles Expert level knowledge and understanding of C#, Unity, and the .NET ecosystem Good, collaborative communication skills. We’re a fully remote studio so we’re looking for candidates who can design, implement, and communicate their development goals and plans easily and effectively to fellow teammates around the world Interest in having high impact and autonomy as the lead of a small, nimble team Player-centric understanding of the development process with good instincts for fun and innovative gameplay and game feel Excitement and flexibility in learning new skills to tackle unfamiliar challenges Strong understanding of event and data-driven game architecture for large scale, systems-driven games Deep and practical understanding of game architecture concepts Expertise in one or more of the following areas: UI/UX Programming, Procedural generation, AI Programming, P2P Networking BONUS: We’d love it if you also have… Experience developing turn-based / strategy games Network engineering experience Experience with Steamworks/Playfab/Platform APIs Interest in tools development Experience with multiple languages, frameworks and tools CI/CD pipeline experience   What’s in it for you? Our culture is centered around trust, communication, and creating space for everyone on our team to make a meaningful impact. We consider ourselves lucky to work with a diverse group of talented folks from all over the world, sharing their expertise and unique perspectives. If you join our ranks, you’ll have many opportunities to pick up new skills. We’d like to help you grow your career, just as you help us build our games! In addition, we offer the following benefits: Competitive salary ($70k - $100k, commensurate with experience) Full time remote work Respect for your work-life balance and flexible hours Unlimited PTO Health Insurance reimbursement through QSEHRA Opportunity to make open source tooling   Our Interview Process We’ve set up a short interview process that we hope is considerate of your time, fairly evaluates you based on your practical experience, and shows our investment in you.   15 - 20 minute intro video call We’ll give you a high level overview of what we’re all about, and learn more about your background, skills, and relevant experience We’d like to learn more about your interests and assess alignment with our studio vision Code sample review We’ll ask you to submit some code you’ve written: a feature, a cool solution to a problem you solved, something you’ve built for a shipped game…whatever you’re proud of! We’ll be looking for: Clean, well-documented code Simplicity and elegance or an interesting approach Adherence to best code practices (understanding of naming conventions, layout consistency, appropriate commenting, etc.) 1 hour deep dive with Kyle Kukshtel, our Founder / Creative Director. You’ll go over: 10 minute hellos and technical discussion around your knowledge of the C#, Unity, and the .NET ecosystems, game architecture, and sensibilities around game “feel” and fun 30 minute targeted live coding session tailored (if possible) to your stated specialty (ex: solve a well-scoped bug) 20 minute “reverse” interview - your chance to ask us any questions you might have about our processes, philosophies, culture, etc. Kyle will be on this call but if there are other folks in other roles you’d be interested in pulling in for this conversation as well, we’ll try to make it happen!   How to Apply Sent a resume and other relevant materials (portfolio, dev blog, LinkedIn, etc.) to careers@afterschool.studio with:   Subject line: Lead Programmer - {your full name} A short statement re: why you think you’d be a good fit or why you want to work with us! What game you are playing right now




aft

Worker Struck by Motorized Bicycles After Happy Hour Event Gets Benefits

A New York appellate court upheld a finding that a worker was entitled to benefits for his injuries from being struck by two motorized bicycles after he left a happy…




aft

Carrier Liable for Worker's Claim After Coverage Ended

A New York appellate court ruled that a carrier was liable for a worker’s claim even though her date of disablement fell after the coverage ended. Though Travelers Indemnity Co. of America's…




aft

Pension Offset Not Available When Retiree Gets Hurt After Returning to Work

The Commonwealth Court of Pennsylvania ruled that a pension offset is not available when the retiree returns to work for a former employer on a part-time basis and suffers an…




aft

WCAB Lacks Jurisdiction to Act on Petition for Recon Over 60 Days After Filing

A California appellate court ruled that the Workers’ Compensation Appeals Board lacks jurisdiction to act on a petition for reconsideration more than 60 days after it was filed. Joseph Mayor worked…




aft

Attorney Can't Seek Fees After Client Settles LHWCA Claim

A federal appellate court ruled that the former attorney for a claimant seeking benefits under the Longshore and Harbor Workers’ Compensation Act could not seek an award of fees after…




aft

Worker Gets PTD Benefits After Symptoms Shift From Left Side of Body to Right

The Iowa Court of Appeals upheld an award of permanent total disability benefits for a worker who experienced issues on his left side after a back injury before symptoms shifted to…




aft

Coal Miner Gets Increased Award Despite Improved Condition After Lung Transplant

The West Virginia Supreme Court ruled that a former coal miner was entitled to an increased impairment award for the worsening of his occupational pneumoconiosis, even though he had undergone…




aft

Trucking Company Fined After Worker Dies in Confined Space

The Minnesota Occupational Safety and Health Administration cited trucking Wayne Transports Inc. after a worker died in a confined space. Justin Erickson, 39, was found dead in the tank of a tanker…




aft

Companies Fined $650,000 After Worker Dies in Storage Facility

Two companies were fined a combined $650,000 after a worker died in an apple storage facility that had a low oxygen level to prevent fruit from spoiling, the Washington State…




aft

Optimizing MSAs: Before & After Settlement

Settling work comp claims calls for a tricky balance. Payers want to limit the amount of money that is allocated to a Medicare Set-Aside and injured workers worry about running…




aft

Worker Who Fell in Elevator Shaft Gets Summary Judgment on Labor Law Claim

A New York appellate court upheld a grant of summary judgment for a worker’s Labor Law claim based on his fall while working in an elevator shaft. Case: De Souza v.




aft

L&I: Felony Charges Filed After Claimant Seen Lifting Weights at Gym

A worker collecting benefits for a back injury is facing fraud charges after he was reportedly observed lifting weights at a gym that exceeded the five-pound restriction his physician imposed,…




aft

OSHA Fines Company $29,035 After Worker Struck by Stone Slab

Federal workplace safety officials fined an Alabama countertop installation company $29,035, saying it could have prevented a worker's death by following federal safety standards. John Hopper, 33, died in March after…




aft

Worker Gets No TTD for Time After Termination Until Back Surgery

The Kentucky Court of Appeals upheld a reduction in a worker’s award of temporary total disability benefits to eliminate compensation for the time after he was terminated up until he…




aft

Employer Should Have Been Granted Continuance After Doctor's Unexpected Change in Opinion

A Florida appellate court ruled that an employer should have been granted a continuance after its medical expert expressed an unforeseen change in opinion shortly before the scheduled hearing on…




aft

Treating gum disease after heart rhythm ablation reduced risk of AFib recurrence

Research Highlights: Treating gum disease within three months after a heart procedure to correct an irregular heart rhythm, known as atrial fibrillation (AFib), may lower the chances of it reoccurring. Inflamed gums may predict AFib recurrence after...




aft

Bystander CPR up to 10 minutes after cardiac arrest may protect brain function

This news release contains updated information and data not included in the abstract. Research Highlights: The sooner a lay rescuer (bystander) starts cardiopulmonary resuscitation (CPR) on a person having a cardiac arrest at home or in public, up to ...




aft

The Superb Papercraft Object Design by Oupas Design

Oupas Design, a creative studio from Portugal, has spent over 12 years crafting playful, custom paper art for brands like Salesforce, Hermès, and The Atlantic. Founded by three friends—Cidália, Joana, and Sofia—the studio’s work reflects their passion and expertise in paper art, evident in their detailed, whimsical creations that bring ideas to life. More: Oupas […]




aft

On Crafting Painterly Shaders

This article is the culmination of months of work, trial and error, and research to craft the perfect painterly shader for your next WebGL project.




aft

Female athletes may be more susceptible to concussion and have prolonged symptoms after concussion

Female athletes are more susceptible to sport-related concussions (SRCs) and experience worse outcomes compared with male athletes. Although numerous studies on SRC have compared the outcomes of concussions in male and female athletes after injury, research pertaining to why female athletes have worse outcomes is limited.




aft

Tagovailoa rejects calls to retire after 3rd official concussion of his NFL career

Miami Dolphins quarterback Tua Tagovailoa is rejecting calls to retire after the third official concussion of his NFL career. 




aft

N.C. State quarterback Grayson McCall retires from football at 23 after concussions

North Carolina State quarterback Grayson McCall is retiring from football, he announced Wednesday after sustaining a head injury during a game earlier this month. "Brain specialists, my family, and I have come to the conclusion that it is in my best interest to hang the cleats up," he continued. "I have done everything I can to continue, but this is where the good Lord has called me to serve in a different space."




aft

A year after Maine mass shooting, gunman's family wants action on brain injury research in military

The family of the Army reservist who committed the October 2023 massacre in Lewiston wants to bring awareness to traumatic brain injuries among military members.




aft

Why Does Everything Hurt So Much After Brain Injury?

More than 50 percent of people suffer from chronic pain disorders in the years following a brain injury. Getting the right treatment can be complex, but doable.




aft

Is It Okay to Engage in Heavy Lifting After a Brain Injury?

Oftentimes balance issues influence restrictions about lifting heavy objects after a brain injury.




aft

Changes in Taste, Smell, and Hormones After Brain Injury

How and why does a TBI change a person’s ability to taste and smell, and cold hands and feet, too?




aft

Can Symptoms of Hypopituitarism Present Years After a Brain Injury?

Symptoms of hypopituitarisma condition in which the pituitary gland does not produce normal amounts of some or all of its hormones would most likely show up soon after a TBI.




aft

Can the Drugs Namenda and Aricept Help After Brain Injury?

Learn about the risks and benefits of these drugs for symptoms of brain injury.




aft

Crafting Impact with Negative Space Photography

Picture a scene where the main act is not just what fills the frame, but also what doesn’t. That’s negative space photography, a technique that turns emptiness into expression and silence into storytelling.

In this deep dive, we’re peeling back layers to reveal how much weight nothingness can hold in your shots.

You’ll grasp why every photographer needs to give their subjects some breathing room and learn how empty areas are not missed opportunities but rather essential for creating balance and drawing attention right where you want it.

We’ll explore ways to use plain backgrounds or blurred surroundings as powerful tools that add feelings of calm, tension, or intrigue—all by letting less say more.

The Essence of Negative Space in Photography

Negative space photography, often seen as the quiet hero of composition, plays a crucial role in how an image is perceived. It’s not just about what you capture—it’s also about what you leave out. This technique can make your main subject pop by simply giving it more breathing room.

Defining Negative Space and Its Role in Visual Composition

Negative space refers to the area surrounding the main subject—or positive space—of a photograph.

Continue reading Crafting Impact with Negative Space Photography



  • Photography Tips & Tricks

aft

The Secret to Lifelong Creativity (Hint: It Doesn’t End After Your 20s)

Creativity doesn’t expire. Chase Jarvis explains how to keep your creative spark alive, no matter your age or life stage.

The post The Secret to Lifelong Creativity (Hint: It Doesn’t End After Your 20s) first appeared on Chase Jarvis.

The post The Secret to Lifelong Creativity (Hint: It Doesn’t End After Your 20s) appeared first on Chase Jarvis.




aft

Crafts With The Fine Arts

The phrase “crafts with the fine arts” captures the connection and interplay between the fields of fine arts and crafts. Fine arts typically include discipl ...




aft

How we use DDEV, Vite and Tailwind with Craft CMS

In 2022 we changed our dev tooling for new Craft CMS projects. Goodbye complex esoteric Webpack configuration, hello Vite. Goodbye complex esoteric Docker Compose configuration, hello DDEV. This small change in tooling has completely transformed our development experience. We start work faster and avoid wasting billable time debugging Webpack and Docker.

From Webpack to Vite #

Webpack has been the defacto way of bundling JavaScript and front end assets. It’s a powerful tool… but with that great power comes great responsibility complexity.

Vite bills itself as the “next generation” of frontend tooling. Vite is much faster at bundling. But more importantly… its default configurations work great for most website projects.

Before (Webpack) #

Well over 300 lines of configuration spanning three files. Good luck making changes!

After (Vite) #

A crisp 30 - 50 lines of code. Want to switch to TypeScript? Need to drop in a popular front-end framework? Easy! All it takes is adding a plugin and 2-3 lines of config.

Deleting old code has never felt this good!

From Docker to DDEV #

Docker is another development staple. It isolates server infrastructure into virtual “containers.” This helps avoid issues that arise from each developer having a slightly different setup. However, Docker can have a learning curve. Config changes, PHP upgrades and unexpected issues often eat up precious project time.

Enter DDEV! DDEV describes itself as “Container superpowers with zero required Docker skills: environments in minutes, multiple concurrent projects, and less time to deployment.” We’ve found that statement to be 100% true.

Before (Docker) #

Every Craft project has a different Docker config. Bugs and upgrades required deep Docker experience. Last (but not least), it was difficult to run several projects at one time (ports often conflict).

After (DDEV) #

Performance is consistently better than our hand-rolled setup thanks to Mutagen and faster DB import/exports. Simultaneous projects run out of the box. DDEV provides (and maintains) a growing list of helpful shortcuts and DX features.

Getting started #

Ready to make the switch? Here’s how to set up DDEV, Vite and Tailwind on your own Craft project.

Show me the config files already! #

If you would rather see full config files instead of following step by step, check out our Craft Site Starter on GitHub.

DDEV #

Let’s set up a fresh DDEV project and start customizing.

  1. Make sure you have DDEV installed on your computer.
  2. If you’re a PHPStorm user, install the exceedingly helpful DDEV plugin. VS Code users have a similar plugin too!
  3. Follow Craft’s guide for creating a new project (they love DDEV too).

Now you have a fresh .ddev/config.yaml just waiting to be customized.

Node Version #

Open your DDEV config and make sure your Node JS version matches Vite’s recommendations.

nodejs_version: '20' # Vite 5 expects Node 18+

Ports for Vite’s dev server #

Next, expose ports that Vite’s dev server uses will use to serve assets.

web_extra_exposed_ports:
  - name: vite
    container_port: 3000
    http_port: 3000
    https_port: 3001

Routing ports can sometimes be confusing. This diagram might help!

  • Vite’s dev server runs inside of DDEV’s web container (a Docker container).
  • Until we expose these extra ports, any custom port within DDEV is unavailable to your host machine (your computer).
  • When it’s time to configure Vite, we’ll use port 3000
  • HTTP and HTTPS traffic must use separate ports.
  • We use port 3000 for http traffic and 3001 for https

Run Vite automatically #

Usually, you’ll want Vite to watch and build files automatically after you start a DDEV project. Using web_extra_daemons adds a separate background process (daemon) for Vite.

web_extra_daemons:
  # Run Vite in a separate process
  - name: 'vite'
    command: 'npm install && npm run dev'
    directory: /var/www/html

Use hooks to improve DX #

DDEV’s powerful hooks system can run tasks before or after various DDEV commands. These post-start tasks keep dependencies and schemas up to date every time you start DDEV.

hooks:
  post-start:
    - composer: install # Keeps installed packages up to date
    - exec: ./craft up # Apply migrations & project config changes

Time for Vite #

Vite is a Node app that’s installed with NPM. Your project will need a package.json. If you don’t have one set up yet, follow NPMs initialization script.

ddev npm init

# Don't forget to ignore node_modules!
echo node_modules >> .gitignore

????Why ddev at the start of the command? This let’s us run NPM from within DDEV’s Docker containers. This means you’ll always be using the Node version configured for this project. DDEV has a bunch of shortcuts and aliases for running CLI commands (such as npm, yarn, craft and composer).

Make sure your NPM package is configured for ES Modules #

Our various config files will be using ES Module syntax for imports and exports.

ddev npm pkg set type=module

Install Vite! #

ddev npm install --save-dev vite

Add convenience scripts to package.json #

"scripts": {
  "dev": "vite",
  "build": "vite build"
}

npm run dev runs Vite in dev mode. It watches and builds your files every save. Files are served through Vite’s dev server.

npm run build bundles your JavaScript, CSS and static images for production. Your deploy process will usually call this script.

Configure vite.config.js #

Running Vite for a server rendered CMS requires some extra configuration. These options put production files in the right spot and keeps Vite’s dev server running on a specific port.

import { defineConfig, loadEnv } from 'vite'

// Match ports in .ddev/config.yaml and config/vite.php
const HTTP_PORT = 3000
const HTTPS_PORT = 3001

export default defineConfig(({ command, mode }) => {
  const env = loadEnv(mode, process.cwd(), '')

  return {
    // In dev mode, we serve assets at the root of https://my.ddev.site:3000
    // In production, files live in the /dist directory
    base: command === 'serve' ? '' : '/dist/',
    build: {
      manifest: true,
      // Where your production files end up
      outDir: './web/dist/',
      rollupOptions: {
        input: {
          // The entry point for Vite, we'll create this file soon
          app: 'src/js/app.js',
        },
      },
    },
    server: {
	    // Special address that respond to all network requests
      host: '0.0.0.0',
	    // Use a strict port because we have to hard code this in vite.php
      strictPort: true,
      // This is the port running "inside" the Web container
      // It's the same as continer_port in .ddev/config.yaml
      port: HTTP_PORT,
      // Setting a specific origin ensures that your fonts & images load
      // correctly. Assumes you're accessing the front-end over https
      origin: env.PRIMARY_SITE_URL + ':' + HTTPS_PORT,
    },
  }
})

Add JavaScript and CSS files (Entrypoint) #

Vite needs an entry point to determine what JavaScript, CSS and Front End assets it needs to compile. Remember src/js/app.js that we defined in vite.config.js? Let's make that file now.

/* Make a file in src/js/app.js */

import '../css/app.css'

console.log('Hello Craft CMS')

We’ll also add our CSS as an import in app.js . In plain-old-JavaScript you can’t import CSS files. However, Vite uses this to figure out CSS dependencies for the project.

Once Vite builds everything for production, you end up with a separate CSS file. The Craft Vite plugin includes this automatically with along your JavaScript bundle.

/* Make a file in src/css/app.css */

body {
	background-color: peachpuff;
}

Install the Vite Craft Plugin #

ddev composer require nystudio107/craft-vite
ddev craft plugin/install vite

Vite assets have different URLs in dev mode vs. production. In dev mode, assets are served from Vite’s dev server. It uses the ports that we defined in our DDEV & Vite configs.

When Vite builds for production, filenames are hashed (app.js becomes app-BZi_KJSq.js). These hashes change when the contents of the file changes. Browser can cache these files indefinitely. When an asset changes, a whole new file is served.

To help find these hashed filenames, Vite creates a manifest.json file. The manifest associates the name of your asset src/js/app.js to the hashed file that ends up on your server web/dist/assets/app-BZi_KJSq.js

The Craft Vite Plugin by NYStudio107 takes care of all this routing for you.

{
  "src/js/app.js": {
    "file": "assets/app-BZi_KJSq.js",
    "name": "app",
    "src": "src/js/app.js",
    "isEntry": true,
    "css": ["assets/app-BXePGY5I.css"]
  }
}

Configure the Vite Craft Plugin #

Make a new plugin config file in config/vite.php

<?php

use crafthelpersApp;

// Use the current host for dev server requests. Otherwise fall back to the primary site.
$host = Craft::$app->getRequest()->getIsConsoleRequest()
    ? App::env('PRIMARY_SITE_URL')
    : Craft::$app->getRequest()->getHostInfo();

return [
    'devServerPublic' => "$host:3001", // Matches https_port in .ddev/config.yaml
    'serverPublic' => '/dist/',
    'useDevServer' => App::env('CRAFT_ENVIRONMENT') === 'dev',
    'manifestPath' => '@webroot/dist/.vite/manifest.json',
    // Optional if using React or Preact
    // 'includeReactRefreshShim' => true,
];

Include your Vite bundles in Twig #

The script and asset functions includes the appropriate files depending on in if you’re in dev mode or production. Clear out your templates/index.twig file and add the following snippet to your <head> tag.

{# Load our main CSS file in dev mode to avoid FOUC #}
{% if craft.vite.devServerRunning() %}
    <link rel="stylesheet" href="{{ craft.vite.asset("src/css/app.css") }}">
{% endif %}

{{ craft.vite.script('src/js/app.js', false) }}

Whew! ???? We’re at a point now where we can test our integration. Run ddev restart and then ddev launch . You should see “Hello Craft CMS” in your browser console.


Setup Tailwind #

Now that Vite is processing src/css/app.css, it’s time to install Tailwind and really get cooking.

These steps are based on Tailwind’s official installation guide. But make sure to run all commands from within DDEV.

Install packages #

ddev npm install -D tailwindcss postcss cssnano autoprefixer
# No DDEV shortcut for npx :(
ddev exec npx tailwindcss init -p

Configure template paths in tailwind.config.js #

/** @type {import('tailwindcss').Config} */
export default {
	// Watch Twig templates and any JS or JSX that might use Tailwind classes.
  content: ['./templates/**/*.twig', './src/**/*.{js,jsx,ts,tsx,svg}'],
  theme: {
    extend: {},
  },
  plugins: [],
}

Configure postcss.config.js for production #

export default {
  plugins: {
    tailwindcss: {},
    autoprefixer: {},
    ...(process.env.NODE_ENV === 'production' ? { cssnano: {} } : {})
  }
}

Add Tailwind directives to src/css/app.css #

@tailwind base;
@tailwind components;
@tailwind utilities;

You’ll most likely need to run ddev restart again to get Vite to recognize your new Tailwind config.


❓ Do i need to set up live reload of Twig? Turns out it’s already done for you! Styling a Tailwind project means editing Twig files to change styles. It’s super handy to reload your browser every time you save. Normally you’d reach for vite-plugin-restart to get this functionality. However, Tailwind’s JIT mode automatically notifies Vite when CSS has compiled and the page should reload.

That's a wrap! #

That’s all it takes to configure a minimal DDEV and Vite project! We’ve found that both of these tools are easy to extend as a project get more complo'ex. Adding things like Redis or React are just a plugin install and a few lines of config away.

???? If you'd like to see this setup (and more) in a real-world Craft CMS project, check out our Craft Site Starter on GitHub.

Go forth and Vite + DDEV to your heart’s desire.