function-with-properties.js 213 B

123456789101112131415161718
  1. function foo () {
  2. return 'hello'
  3. }
  4. foo.bar = 'baz'
  5. foo.nested = {
  6. prop: 'yes'
  7. }
  8. foo.method1 = function () {
  9. return 'world'
  10. }
  11. foo.method1.prop1 = function () {
  12. return 123
  13. }
  14. module.exports = {
  15. foo: foo
  16. }