spyne 0.16.0 → 0.18.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.
Files changed (81) hide show
  1. package/.travis.yml +2 -2
  2. package/karma.conf.js +18 -69
  3. package/lib/spyne.js +29752 -28672
  4. package/lib/spyne.min.js +1 -1
  5. package/lib/spyne.min.js.LICENSE.txt +9 -9
  6. package/package.json +21 -42
  7. package/src/spyne/channels/channel-fetch-class.js +25 -5
  8. package/src/spyne/channels/channel-payload-class.js +36 -23
  9. package/src/spyne/channels/channel-proxy.js +7 -5
  10. package/src/spyne/channels/channel.js +54 -28
  11. package/src/spyne/channels/channels-config.js +2 -4
  12. package/src/spyne/channels/{channels-delegator.js → channels-map.js} +25 -41
  13. package/src/spyne/channels/spyne-channel-lifecycle.js +1 -2
  14. package/src/spyne/channels/spyne-channel-route.js +21 -62
  15. package/src/spyne/channels/spyne-channel-ui.js +1 -2
  16. package/src/spyne/channels/spyne-channel-window.js +24 -35
  17. package/src/spyne/spyne-app.js +163 -0
  18. package/src/spyne/spyne-plugins.js +43 -40
  19. package/src/spyne/spyne.js +6 -157
  20. package/src/spyne/utils/channel-config-validator.js +0 -1
  21. package/src/spyne/utils/channel-fetch-util.js +1 -2
  22. package/src/spyne/utils/channel-payload-filter.js +9 -76
  23. package/src/spyne/utils/frp-tools.js +21 -1
  24. package/src/spyne/utils/gc.js +1 -1
  25. package/src/spyne/utils/route-channel-updater.js +0 -4
  26. package/src/spyne/utils/spyne-app-properties.js +183 -0
  27. package/src/spyne/utils/spyne-logger.js +18 -0
  28. package/src/spyne/utils/spyne-plugins-methods.js +97 -0
  29. package/src/spyne/utils/spyne-trait.js +2 -5
  30. package/src/spyne/utils/spyne-utils-channel-route-url.js +3 -8
  31. package/src/spyne/utils/spyne-utils-channel-route.js +6 -14
  32. package/src/spyne/utils/spyne-utils-channel-window.js +1 -3
  33. package/src/spyne/utils/viewstream-observables.js +2 -3
  34. package/src/spyne/views/dom-element-template.js +2 -7
  35. package/src/spyne/views/dom-element.js +0 -19
  36. package/src/spyne/views/view-stream-broadcaster.js +5 -10
  37. package/src/spyne/views/view-stream-element.js +1 -18
  38. package/src/spyne/views/view-stream-payload.js +31 -37
  39. package/src/spyne/views/view-stream-selector.js +3 -8
  40. package/src/spyne/views/view-stream.js +281 -297
  41. package/src/tests/channels/channel-fetch.test.js +102 -0
  42. package/src/tests/channels/channel-payload-class.test.js +14 -5
  43. package/src/tests/channels/channel-payload-filter.test.js +3 -28
  44. package/src/tests/channels/channel.test.js +38 -0
  45. package/src/tests/index.js +0 -1
  46. package/src/tests/index.test.js +6 -0
  47. package/src/tests/spyne-app.test.js +27 -0
  48. package/src/tests/spyne-plugin.test.js +13 -9
  49. package/src/tests/utils/plugins-methods.test.js +103 -0
  50. package/src/tests/utils/spyne-app-properties.test.js +11 -0
  51. package/webpack.config.js +19 -34
  52. package/lib/channel-action-filter.test.3516417154.js +0 -20
  53. package/lib/channel-dom.test.104366832.js +0 -20
  54. package/lib/channel-fetch-util.test.3506167575.js +0 -20
  55. package/lib/channel-payload-class.test.1081032524.js +0 -20
  56. package/lib/channel-payload-filter.test.977308429.js +0 -20
  57. package/lib/channel-route.test.3513636042.js +0 -20
  58. package/lib/channel-stream-item.test.119388071.js +0 -20
  59. package/lib/channel-ui.test.3778619579.js +0 -20
  60. package/lib/channel-util-dom.test.908537750.js +0 -20
  61. package/lib/commons.js +0 -49268
  62. package/lib/dom-el-selectors.test.1268485916.js +0 -20
  63. package/lib/dom-el-template.test.842696987.js +0 -20
  64. package/lib/dom-el.test.2045076905.js +0 -20
  65. package/lib/frp-tools.test.2503042868.js +0 -20
  66. package/lib/import.test.2658619365.js +0 -20
  67. package/lib/index.test.2372977745.js +0 -20
  68. package/lib/route-utils.test.273346057.js +0 -20
  69. package/lib/runtime.js +0 -172
  70. package/lib/spyne-plugin.test.301647328.js +0 -20
  71. package/lib/spyne.js.map +0 -1
  72. package/lib/url-utils.test.1931189114.js +0 -20
  73. package/lib/view-stream-broadcaster.test.1306675435.js +0 -20
  74. package/lib/view-stream-enhancer-loader.test.3617829096.js +0 -20
  75. package/lib/view-stream-enhancer.test.1053738169.js +0 -20
  76. package/lib/view-stream.test.573231784.js +0 -20
  77. package/src/spyne/channels/lifestream-payload.js +0 -56
  78. package/src/spyne/utils/channel-data-packet-generator.js +0 -200
  79. package/src/spyne/utils/channel-data-packet.js +0 -59
  80. package/src/spyne/utils/viewstream-dom-utils.js +0 -51
  81. package/src/spyne/views/view-stream-enhancer-loader.js +0 -70
package/.travis.yml CHANGED
@@ -3,11 +3,11 @@ cache:
3
3
  directories:
4
4
  - ~/.npm
5
5
  services:
6
- - xvfb
6
+ - xvfb
7
7
  notifications:
8
8
  email: false
9
9
  node_js:
10
- - '8'
10
+ - '14'
11
11
  before_script:
12
12
  - npm prune
13
13
  script:
package/karma.conf.js CHANGED
@@ -1,14 +1,11 @@
1
- // Karma configuration
2
- // Generated on Fri Mar 31 2017 02:40:49 GMT-0400 (EDT)
3
- const webpackEnv = {test:true};
4
- //const webpackConfig = require("./webpack.config")(webpackEnv);
1
+
5
2
  const webpackConfig = require("./webpack.config");
6
- webpackConfig.mode = 'development';
3
+ webpackConfig.mode = 'none';
7
4
  webpackConfig.watch = true;
8
- webpackConfig.output.filename='[name].[hash:8].js';
5
+ webpackConfig.entry = undefined;
6
+ webpackConfig.output = undefined;
7
+
9
8
  const fileGlob = './src/tests/index.test.js';
10
- process.env.BABEL_ENV = 'test';
11
- //const rxjs = require("rxjs");
12
9
 
13
10
 
14
11
  module.exports = function(config) {
@@ -18,32 +15,12 @@ module.exports = function(config) {
18
15
  }
19
16
 
20
17
 
21
-
22
-
23
18
  webpackConfig.module.rules.push(
24
19
  {
25
20
  test: /(\.js)$/,
26
- loader: 'babel-loader',
27
-
28
- options: {
29
- "babelrc" : false,
30
- "presets": [
31
- ["@babel/preset-env", {
32
- "targets": {
33
- "ie" : 10,
34
- "browsers": ["last 2 versions"]
35
-
36
- },
37
- "modules": false,
38
- "loose": true
39
- }]
40
- ]
41
- },
42
21
  exclude: /(node_modules)/
43
22
  }
44
-
45
23
  );
46
- console.log("CONFIG KARMA ",webpackConfig);
47
24
 
48
25
 
49
26
  config.set({
@@ -56,22 +33,25 @@ module.exports = function(config) {
56
33
 
57
34
  },
58
35
 
59
- // frameworks to use
60
36
  // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
61
37
  frameworks: ['webpack', 'mocha', 'chai'],
62
38
 
39
+ plugins: [
40
+ 'karma-webpack',
41
+ 'karma-mocha',
42
+ 'karma-chai',
43
+ 'karma-coverage',
44
+ 'karma-chrome-launcher'
45
+ ],
46
+
63
47
 
64
- // list of files / patterns to load in the browser
65
48
  files: [
66
- {pattern: './node_modules/spynejs-polyfill/ie.js', watched:false},
67
49
  {pattern: './node_modules/ramda/dist/ramda.min.js', watched:false},
68
-
69
- { pattern: './node_modules/rxjs/*.js', included:false, watched: false },
70
50
  { pattern: './node_modules/rxjs/**/*.js', included:false, watched: false },
71
51
 
72
-
73
- {pattern: './src/tests/*.test.js', watched: true},
74
-
52
+ {pattern: './src/tests/index.test.js', watched: true},
53
+ {pattern: './src/tests/spyne-app.test.js', watched: true},
54
+ {pattern: './src/tests/spyne-plugin.test.js', watched: true},
75
55
  {pattern: './src/tests/channels/*.test.js', watched: true},
76
56
 
77
57
  {pattern: './src/tests/utils/*.test.js', watched: true},
@@ -79,9 +59,6 @@ module.exports = function(config) {
79
59
  ],
80
60
 
81
61
 
82
-
83
-
84
- // list of files to exclude
85
62
  exclude: [
86
63
 
87
64
  ],
@@ -106,18 +83,6 @@ module.exports = function(config) {
106
83
  // available reporters: https://npmjs.org/browse/keyword/karma-reporter
107
84
  reporters: ['coverage'],
108
85
 
109
- /*
110
- coverageReporter: {
111
- reporters: [
112
- {type: 'lcov', dir: 'coverage/', subdir: '.'},
113
- {type: 'text-summary'}
114
-
115
-
116
- ]
117
- },
118
- */
119
-
120
-
121
86
  coverageReporter: {
122
87
  reporters: [
123
88
  // generates ./coverage/lcov.info
@@ -142,36 +107,20 @@ module.exports = function(config) {
142
107
 
143
108
  // enable / disable watching file and executing tests whenever any file changes
144
109
  autoWatch: true,
145
-
146
-
110
+ usePolling: true,
147
111
 
148
112
  customLaunchers: {
149
-
150
113
  ChromeHeadlessNoSandbox: {
151
114
  base: 'ChromeHeadless',
152
115
  flags: ['--no-sandbox']
153
- },
154
-
155
- VirtualBoxIE11onWin7: {
156
- base: 'VirtualBoxIE11',
157
- keepAlive: true,
158
- snapshot: 'pristine',
159
- uuid: '0552dac4-c8f0-4d29-b81a-ae70026505c5'
160
- }
161
-
162
-
116
+ }
163
117
 
164
118
  },
165
119
 
166
120
 
167
-
168
121
  // start these browsers
169
122
  // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
170
123
  browsers: ['Chrome'],
171
- /*
172
- browsers: ['Chrome','VirtualBoxIE11onWin7'],
173
- */
174
-
175
124
 
176
125
  // Continuous Integration mode
177
126
  // if true, Karma captures browsers, runs the tests and exits