Skip to content

Commit

Permalink
Re-organize: Move resources/js|scss to resources/app|styles
Browse files Browse the repository at this point in the history
  • Loading branch information
gdarko committed Jun 2, 2024
1 parent 6843a9e commit 0de9e7f
Show file tree
Hide file tree
Showing 69 changed files with 16 additions and 14 deletions.
4 changes: 2 additions & 2 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ root = true
[*]
charset = utf-8
end_of_line = lf
insert_final_newline = true
indent_style = space
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[*.md]
Expand Down
1 change: 0 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,5 @@ AWS_USE_PATH_STYLE_ENDPOINT=false
VITE_APP_NAME="${APP_NAME}"

# Customizations
APP_LOGO=/assets/images/logo.png
SANCTUM_STATEFUL_DOMAINS=yourdomain.test
SESSION_DOMAIN=yourdomain.test
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ For your convenience the project comes with complete `users` crud that includes

### ➡️ Structure

The front-end code is located in `resources/js`. The code is organized in different directories to make things more readable.
The front-end code is located in `resources/app`. The code is organized in different directories to make things more readable.

| Directory | Description |
|--------------|---------------------------------------|
Expand Down
2 changes: 1 addition & 1 deletion jsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@/*": ["./resources/js/*"]
"@/*": ["./resources/app/*"]
}
}
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions resources/views/index.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<title>{{env('APP_NAME')}}</title>

@vite(['resources/scss/main.scss', 'resources/js/main.js'])
@vite(['resources/styles/main.scss', 'resources/app/main.js'])

<script>
window.AppConfig = {
name: '{{ env('APP_NAME') }}',
logo: '{{ env('APP_LOGO') }}',
logo: '{{ url('/assets/images/logo.png') }}',
url: '{{ env('APP_URL') }}',
csrf: '{{ csrf_token() }}',
defaultLocale: '{{ env('APP_LOCALE', 'en') }}',
Expand Down
2 changes: 1 addition & 1 deletion tailwind.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
const colors = require('tailwindcss/colors');

module.exports = {
content: ["./resources/js/**/*.html", "./resources/js/**/*.vue"],
content: ["./resources/app/**/*.html", "./resources/app/**/*.vue"],
theme: {
extend: {
colors: {
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

"baseUrl": ".",
"paths": {
"@/*": ["./resources/js/*"]
"@/*": ["./resources/app/*"]
},

"module": "ESNext",
Expand Down
13 changes: 8 additions & 5 deletions vite.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,13 @@ export default defineConfig({
__INTLIFY_PROD_DEVTOOLS__: false,
},
plugins: [
laravel([
'resources/scss/main.scss',
'resources/js/main.js',
]),
laravel({
input: [
'resources/styles/main.scss',
'resources/app/main.js',
],
refresh: true,
}),
vue({
template: {
transformAssetUrls: {
Expand All @@ -35,7 +38,7 @@ export default defineConfig({
],
resolve: {
alias: {
'@': path.resolve(__dirname, './resources/js'),
'@': path.resolve(__dirname, './resources/app'),
},
extensions: ['.js', '.ts', '.jsx', '.tsx', '.json', '.vue', '.mjs']
}
Expand Down

0 comments on commit 0de9e7f

Please sign in to comment.