js_dependency 0.4.0 → 0.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 16849080f31654121c34449373ebff1848e5529586ce48f0ceb42169efb91652
4
- data.tar.gz: 4430ca0ea3d689f829bb9dd5ebda28d43b1594979acbe977fe67a1fb8dd2f35e
3
+ metadata.gz: b6012cddd2cb701448c1243a3b7cf444bc144852935460b00e3065518451c7ee
4
+ data.tar.gz: 9d5a37df572c77dae170431eb38d81133b0877a6d10a47492c5062579613a106
5
5
  SHA512:
6
- metadata.gz: a68498b0b19fc9210d3e5b9a5b1bf311b4953c4dc11514af91ebb4c3e1b235e11c68468db643021b1bbbe2189417e5e4fe1d442561ca5f34873d456bd924cc7b
7
- data.tar.gz: 2a0b1b81acd03a8acf0153219f622887ff262a806c636eb5e73db489744c686a227791bdbae01b4a9a9dbea74a66d469d0e5bc852427d733da42d463d7a0b9b0
6
+ metadata.gz: 811ffb4340bb7b26ae1c19a51c369d052a032175bc655f194fa51c687167659b159ce877706532ad329bccc835b300cb007123a4c3864b81bc8625375b40471c
7
+ data.tar.gz: 73c92c3b0ecfdb9b2885810532f0d5556aac5881ee4e82429e01c712acee1ab56ea5d5459c3438909e168310d129ece31264cff29fb5f5618504554fa6f2e179
data/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  ## [Unreleased]
2
2
 
3
+ ## [0.4.1] - 2024-04-01
4
+
5
+ - Add support ts and tsx file. [#38](https://github.com/junara/js_dependency/pull/38)
6
+
3
7
  ## [0.4.0] - 2024-03-31
4
8
 
5
9
  - Breaking change: Support only Ruby 3.0 or later. [#34](https://github.com/junara/js_dependency/pull/34)
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- js_dependency (0.4.0)
4
+ js_dependency (0.4.1)
5
5
  thor
6
6
  yaml
7
7
 
@@ -42,14 +42,14 @@ module JsDependency
42
42
  # @param [Array<String>] alias_paths
43
43
  # @return [Hash]
44
44
  def index_from(src_pathname, alias_paths)
45
- pattern = %w[**/*.vue **/*.js **/*.jsx]
45
+ pattern = %w[**/*.vue **/*.js **/*.jsx **/*.ts **/*.tsx]
46
46
 
47
47
  src_pathname.glob(pattern).each_with_object({}) do |component_pathname, obj|
48
48
  import_pathnames = import_pathnames_from(component_pathname, alias_paths)
49
49
  import_pathnames += src_javascript_pathnames_from(component_pathname, alias_paths)
50
50
 
51
51
  obj[component_pathname.to_s] = import_pathnames.map(&:to_s)
52
- if component_pathname.basename.to_s == "index.js"
52
+ if component_pathname.basename.to_s == "index.js" || component_pathname.basename.to_s == "index.ts"
53
53
  obj[component_pathname.dirname.to_s] =
54
54
  import_pathnames.map(&:to_s)
55
55
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module JsDependency
4
- VERSION = "0.4.0"
4
+ VERSION = "0.4.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: js_dependency
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.0
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - junara