donnikitos/vite-plugin-php

The "HTML Env Replacement" feature is not work inside the <?php ?> tag

Closed this issue · 1 comments

The "HTML Env Replacement" feature is not work inside the tag.

Issue:

  • Input
// path: env/.env
VITE_ENV=development

// path: index.php
<?php $env = "%VITE_ENV%";?>
  • Output (Issue)
// path: index.php
<?php $env = "%VITE_ENV%";?>
  • Expected output
// path: index.php
<?php $env = "development";?>

Uh, that's an interesting one since the PHP snippets are
inserted post compilation 🤔
But I agree - it is definitely a nice feature to have!
Will definitely look into it.