WIP: ES6 module conversion and webpack refactoring
- Convert all IIFE modules to ES6 modules with attach functions - Split webpack configs: lib build vs demo build - Add UMD wrapper for auto-initialization with jQuery - Update package.json with sequential build scripts - Clean up legacy dist files and reorganize demo structure Status: jQuery timing issues remain - attach functions not accessible Next: Debug UMD factory execution and jQuery parameter passing
This commit is contained in:
Binary file not shown.
|
After Width: | Height: | Size: 509 B |
Binary file not shown.
|
After Width: | Height: | Size: 1.8 KiB |
+10
-8
@@ -1,7 +1,9 @@
|
||||
import $ from 'jquery';
|
||||
// Ensure jQuery is available globally before any other imports
|
||||
// Ensure jQuery is available globally before importing x-editable
|
||||
window.$ = window.jQuery = $;
|
||||
global.$ = global.jQuery = $;
|
||||
if (typeof global !== 'undefined') {
|
||||
global.$ = global.jQuery = $;
|
||||
}
|
||||
|
||||
import "bootstrap"
|
||||
import "bootstrap/dist/css/bootstrap.min.css"
|
||||
@@ -11,15 +13,15 @@ import "bootstrap-icons/font/bootstrap-icons.min.css"
|
||||
import "bootstrap-datepicker";
|
||||
import "bootstrap-datepicker/dist/css/bootstrap-datepicker.min.css";
|
||||
|
||||
|
||||
// Import the editable functionality (attaches to jQuery.fn) - using built distribution
|
||||
// When using built files, you need to include select2 separately for select2 inputs
|
||||
// Import select2 before x-editable
|
||||
import "select2";
|
||||
import "select2/dist/css/select2.min.css";
|
||||
import '../dist/bootstrap5-editable/js/bootstrap-editable.min.js'
|
||||
import '../dist/bootstrap5-editable/css/bootstrap-editable.css'
|
||||
|
||||
$.fn.editable.defaults.mode = 'inline';
|
||||
// Import the editable functionality - should be synchronous
|
||||
import 'dist/bootstrap5-editable/js/bootstrap-editable.js'
|
||||
import 'dist/bootstrap5-editable/css/bootstrap-editable.css'
|
||||
|
||||
// $.fn.editable.defaults.mode = 'inline';
|
||||
|
||||
$(function() {
|
||||
|
||||
|
||||
Vendored
BIN
Binary file not shown.
|
After Width: | Height: | Size: 509 B |
Vendored
BIN
Binary file not shown.
|
After Width: | Height: | Size: 1.8 KiB |
Vendored
+1307
File diff suppressed because one or more lines are too long
Vendored
BIN
Binary file not shown.
BIN
Binary file not shown.
Binary file not shown.
Binary file not shown.
+1
-1
@@ -7,7 +7,7 @@
|
||||
<link rel="stylesheet" href="./dist/bootstrap5-editable/css/bootstrap-editable.css">
|
||||
<!-- <script src="./dist/bootstrap5-editable/js/bootstrap-editable.js"></script>-->
|
||||
<!-- <script src="./dist/jquery.js"></script>-->
|
||||
<script src="./dist/app.js" type="module"></script>
|
||||
<script src="./demo/dist/app.js" type="module"></script>
|
||||
|
||||
<title>Bootstrap 5.3.3 Test</title>
|
||||
</head>
|
||||
|
||||
Reference in New Issue
Block a user