diff playground/BUILD @ 12:de54585a40f1

Adding bun and node modules.
author June Park <parkjune1995@gmail.com>
date Thu, 02 Oct 2025 14:39:48 -0700
parents adcfad6e86fb
children 2b9e75756825
line wrap: on
line diff
--- a/playground/BUILD	Tue Sep 30 05:01:34 2025 -0700
+++ b/playground/BUILD	Thu Oct 02 14:39:48 2025 -0700
@@ -1,4 +1,5 @@
 load("@rules_cc//cc:cc_binary.bzl", "cc_binary")
+load("//gui_ze:gui_ze.bzl", "bun_build", "move_to_directory")
 
 alias(
   name = "playground",
@@ -10,5 +11,28 @@
 cc_binary(
   name = "playground_osx",
   srcs = ["main.c"],
-  deps = [],
+)
+
+# TODO: Testing out if I can create a symlink for this.
+move_to_directory(
+  name = "node_modules",
+  data = ["//third_party/bun:node_modules"],
+  dest = "",
 )
+
+filegroup(
+  name = "all_ts_files",
+  srcs = glob([
+      "**/*.ts",
+      "**/*.tsx",
+      "**/*.js",
+      "**/*.jsx",
+  ], allow_empty=True)
+)
+
+bun_build(
+  name = "playground_tsx",
+  src = "main.ts",
+  data = ["//third_party/bun:node_modules", ":all_ts_files"],
+  visibility = ["//visibility:public"],
+)