We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 803513a commit 4cfdf8bCopy full SHA for 4cfdf8b
ruby/ql/test/library-tests/dataflow/erb/main.rb
@@ -16,4 +16,10 @@ def run3
16
view = View3.new(x)
17
render(view)
18
end
19
+
20
+ def run4
21
+ x = source(5)
22
+ view = View4.new(x)
23
+ render(view)
24
+ end
25
ruby/ql/test/library-tests/dataflow/erb/view4.rb
@@ -0,0 +1,15 @@
1
+# This component has no corresponding template file, because it defines a `call` method instead.
2
3
+class View4 < ViewComponent::Base
4
+ def initialize(x)
5
+ @x = x
6
7
8
+ def get
9
+ @x
10
11
12
+ def call
13
+ "hi"
14
15
+end
0 commit comments