rswag-ui 2.12.0 → 2.13.0

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: 4a053278f533d619e1513d32dc3e38e943dd24c9ad38fddc4214cf1b5ebb8880
4
- data.tar.gz: 57fd479e32c5cef6ff17f052614b3408d305ca1e8a56eb6980ab870460f35457
3
+ metadata.gz: 3974cf8486beb436cdf6c45c2f08773e02485f932b5697fe0e859e19d4166e39
4
+ data.tar.gz: 24fdef3744a7dde26ce81c702d581257b4cec64bdf9aeb244726665b16b1f7e3
5
5
  SHA512:
6
- metadata.gz: 56c555dde03031cf0cb2ed1c59464195788be1a730971f1163501f8b341842573030d8ae7548590028145acc4077601b3544732e42a45fd7c539ab4698dc7382
7
- data.tar.gz: 51fb270be2c9df31cd52f1cfe914918c88b57c71aea83b096ea11a828003f812c3c99580fcd170954af10d513d8c470bf2859f64d27889c76a46d04befafe05b
6
+ metadata.gz: 5dc7072ef0ef2ccf84adf796db1a5ba251ad5ed3830898d4c8d028ed0ec3653b33bc0c2d743477b719412dca065614315daacf2b84d980fc52eabe1193fc0ec9
7
+ data.tar.gz: 479f7d983edbe0ded205c07691b885b21b0ae711d20b314006cccbd4eb19d32ac3b45459a42f38a28e6d2847a81954bb546b46e3ca799e303cb3ea9e17d6a740
@@ -5,7 +5,7 @@ Rswag::Ui.configure do |c|
5
5
  # host) to the corresponding endpoint and the second is a title that will be
6
6
  # displayed in the document selector.
7
7
  # NOTE: If you're using rspec-api to expose Swagger files
8
- # (under swagger_root) as JSON or YAML endpoints, then the list below should
8
+ # (under openapi_root) as JSON or YAML endpoints, then the list below should
9
9
  # correspond to the relative paths for those endpoints.
10
10
 
11
11
  c.swagger_endpoint '/api-docs/v1/swagger.yaml', 'API V1 Docs'
@@ -26,7 +26,11 @@ module Rswag
26
26
  end
27
27
 
28
28
  def swagger_endpoint(url, name)
29
- ActiveSupport::Deprecation.warn('Rswag::Ui: WARNING: The method will be renamed to "openapi_endpoint" in v3.0')
29
+ Rswag::Ui.deprecator.warn('Rswag::Ui: WARNING: The method will be renamed to "openapi_endpoint" in v3.0')
30
+ openapi_endpoint(url, name)
31
+ end
32
+
33
+ def openapi_endpoint(url, name)
30
34
  @config_object[:urls] ||= []
31
35
  @config_object[:urls] << { url: url, name: name }
32
36
  end
data/lib/rswag/ui.rb CHANGED
@@ -10,5 +10,9 @@ module Rswag
10
10
  def self.config
11
11
  @config ||= Configuration.new
12
12
  end
13
+
14
+ def self.deprecator
15
+ @deprecator ||= ActiveSupport::Deprecation.new('3.0', 'rswag-ui')
16
+ end
13
17
  end
14
18
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rswag-ui
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.12.0
4
+ version: 2.13.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Richie Morris
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2023-11-25 00:00:00.000000000 Z
13
+ date: 2023-11-29 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: actionpack