Skip to content

Commit

Permalink
Сохранение видео от имени пользователя
Browse files Browse the repository at this point in the history
  • Loading branch information
Spliterash committed Oct 16, 2024
1 parent bb78884 commit fd55cfe
Show file tree
Hide file tree
Showing 51 changed files with 7,729 additions and 30 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,5 @@ build
/application.yml
natives
/.kotlin
front/node_modules
front/dist
31 changes: 31 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
import com.github.gradle.node.npm.task.NpmTask

plugins {
// `java-library`
kotlin("jvm") version "2.0.0"
kotlin("kapt") version "2.0.0"
id("com.github.johnrengelman.shadow") version "8.1.1"
id("io.micronaut.minimal.application") version "4.3.3"


id("com.github.node-gradle.node") version "7.1.0"
}

group = "ru.spliterash"
Expand Down Expand Up @@ -60,4 +65,30 @@ dependencies {
implementation("org.apache.commons:commons-compress:1.27.1")
implementation("io.v47.jaffree:jaffree:1.0.0")

}

node {
version.set("20.18.0")
download.set(true)
}

val buildFront by tasks.registering(NpmTask::class) {
description = "Собирает фронтенд проект"
workingDir.set(file("${projectDir}/front"))
args.set(listOf("run", "build"))

inputs.files(fileTree("front/src"))
inputs.file("front/package.json")

outputs.dir("front/build")
}

val copyFrontToBuildResources by tasks.registering(Copy::class) {
dependsOn(buildFront)
from(file("${projectDir}/front/build/").absoluteFile.path)
into(file(layout.buildDirectory.file("resources/main/miniapp/")))
}

tasks.named<ProcessResources>("processResources") {
dependsOn(copyFrontToBuildResources)
}
2 changes: 2 additions & 0 deletions front/.env
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
VITE_APP_HOST=https://video_unlocker.spliterash.ru
PUBLIC_URL=https://video_unlocker.spliterash.ru/miniapp
2 changes: 2 additions & 0 deletions front/.env.development
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
VITE_APP_HOST=http://localhost:8080
PUBLIC_URL=
15 changes: 15 additions & 0 deletions front/.eslintrc.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
module.exports = {
root: true,
env: { browser: true, es2020: true },
extends: [
'eslint:recommended',
'plugin:@typescript-eslint/recommended',
'plugin:react-hooks/recommended',
],
ignorePatterns: ['dist', '.eslintrc.cjs'],
parser: '@typescript-eslint/parser',
plugins: ['react-refresh'],
rules: {
'react-refresh/only-export-components': ['warn', { allowConstantExport: true }],
},
};
3 changes: 3 additions & 0 deletions front/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# VideoUnlocker FRONT

Небольшая вкшная miniapp'ка для сохранения видео от имени пользователей.
16 changes: 16 additions & 0 deletions front/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" type="image/svg+xml" href="/logo.svg" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, shrink-to-fit=no, user-scalable=no, viewport-fit=cover"
/>
<title>VK Mini App Boilerplate</title>
</head>
<body>
<div id="root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>
Loading

0 comments on commit fd55cfe

Please sign in to comment.