Giter Club home page Giter Club logo

tailwind_cli's Introduction

Hey Devs!

This is your buddy Shoaib Khan from DevsBuddy, My primary objective is to develop exceptional projects that can be of great value to fellow developers.

In addition, I am actively engaged in developing few other personal projects which will be published shortly. These endeavors are intended to provide developers with valuable knowledge, tips, and tricks that they can utilize and share.

tailwind_cli's People

Contributors

iamspydey avatar shoaibkhan404 avatar thedevsbuddy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

tailwind_cli's Issues

Use strings instead

Awesome library!

Wouldn't it be better to infer the styles from strings instead; that way you get tailwind shorthand niceness.

Example

TwText("sometext", class="mt6 pl5 [some tailwind class name etc]")

Build command returns error

I might be doing something wrong since this is the first time I try to install packages onto Flutter, but I am getting the following errors:

Running flutter pub run tailwind_cli:build returns:

Deprecated. Use dart run instead.
Building package executable...
Built tailwind_cli:build.
Unhandled exception:
Synchronous waiting using dart:cli waitFor and C API Dart_WaitForEvent is deprecated and disabled by default. This feature will be fully removed in Dart 3.4 release. You can currently still enable it by passing --enable_deprecated_wait_for to the Dart VM. See https://dartbug.com/52121.
dart:cli-patch/cli_patch.dart 9:47 _waitForEvent
dart:cli/wait_for.dart 64:12 _WaitForUtils.waitForEvent
dart:cli/wait_for.dart 152:19 waitFor
package:dcli/src/util/wait_for_ex.dart 38:17 waitForEx
package:dcli/src/functions/create_dir.dart 39:5 createDir
package:tailwind_cli/src/utilities/Utils.dart 22:7 Utils.makeDir
package:tailwind_cli/src/UtilityGenerator.dart 24:9 generateTwServiceUtility
package:tailwind_cli/src/UtilityGenerator.dart 13:9 generate
../../../.pub-cache/hosted/pub.dev/tailwind_cli-0.7.2/bin/build.dart 15:26 main
dart:isolate-patch/isolate_patch.dart 295:33 _delayEntrypointInvocation.
dart:isolate-patch/isolate_patch.dart 184:12 _RawReceivePort._handleMessage
package:dcli/src/util/wait_for_ex.dart 35:28 waitForEx
package:dcli/src/functions/create_dir.dart 39:5 createDir
package:tailwind_cli/src/utilities/Utils.dart 22:7 Utils.makeDir
package:tailwind_cli/src/UtilityGenerator.dart 24:9 generateTwServiceUtility
package:tailwind_cli/src/UtilityGenerator.dart 13:9 generate
../../../.pub-cache/hosted/pub.dev/tailwind_cli-0.7.2/bin/build.dart 15:26 main
dart:isolate-patch/isolate_patch.dart 295:33 _delayEntrypointInvocation.
dart:isolate-patch/isolate_patch.dart 184:12 _RawReceivePort._handleMessage

If I then try to run dart run tailwind_cli:build I get the following:

Building package executable... (2.9s)
Built tailwind_cli:build.
Unhandled exception:
Synchronous waiting using dart:cli waitFor and C API Dart_WaitForEvent is deprecated and disabled by default. This feature will be fully removed in Dart 3.4 release. You can currently still enable it by passing --enable_deprecated_wait_for to the Dart VM. See https://dartbug.com/52121.
dart:cli-patch/cli_patch.dart 9:47 _waitForEvent
dart:cli/wait_for.dart 64:12 _WaitForUtils.waitForEvent
dart:cli/wait_for.dart 152:19 waitFor
package:dcli/src/util/wait_for_ex.dart 38:17 waitForEx
package:dcli/src/functions/create_dir.dart 39:5 createDir
package:tailwind_cli/src/utilities/Utils.dart 22:7 Utils.makeDir
package:tailwind_cli/src/UtilityGenerator.dart 24:9 generateTwServiceUtility
package:tailwind_cli/src/UtilityGenerator.dart 13:9 generate
../../../.pub-cache/hosted/pub.dev/tailwind_cli-0.7.2/bin/build.dart 15:26 main
dart:isolate-patch/isolate_patch.dart 295:33 _delayEntrypointInvocation.
dart:isolate-patch/isolate_patch.dart 184:12 _RawReceivePort._handleMessage
package:dcli/src/util/wait_for_ex.dart 35:28 waitForEx
package:dcli/src/functions/create_dir.dart 39:5 createDir
package:tailwind_cli/src/utilities/Utils.dart 22:7 Utils.makeDir
package:tailwind_cli/src/UtilityGenerator.dart 24:9 generateTwServiceUtility
package:tailwind_cli/src/UtilityGenerator.dart 13:9 generate
../../../.pub-cache/hosted/pub.dev/tailwind_cli-0.7.2/bin/build.dart 15:26 main
dart:isolate-patch/isolate_patch.dart 295:33 _delayEntrypointInvocation.
dart:isolate-patch/isolate_patch.dart 184:12 _RawReceivePort._handleMessage

Question about readme

In the readme of this repo you wrote

"I know there is one package called VelocityX which does the same thing but there are some issues with that package."
I would like to know what issues VelocityX has that tailwind_cli solved, and what the advantages and disadvantages of using tailwind_cli over VelocityX

Deprecated docs instruction

In the docs you wrote to run this but it failed:

C:\ >flutter pub run tailwind_cli:init
Deprecated. Use `dart run` instead.
Building package executable... (8.2s)
Failed to build tailwind_cli:init:

This worked:

C:\>dart run tailwind_cli:init
Building package executable... 
Built tailwind_cli:init.
Config file generated successfully!

Missing file /extensions/TwContextExtension.dart

Hey, I'm excited with this project :) Thank you for creating it.

I'm getting this error when trying to run my Flutter app:

tailwind/lib/tailwind.dart:7:1: Error: Error when reading 'tailwind/lib/extensions/TwContextExtension.dart': No such file or directory
export "./extensions/TwContextExtension.dart";

I'm willing to help fixing it but I don't know where to start.

flutter pub run tailwind_cli:build. Null check operator used on a null value

flutter pub run tailwind_cli:build
Utilities Generated successfully!
Tailwind file generated successfully!
Utilities Generated successfully!
Pubspec YAML file generated successfully!
Unhandled exception:
Null check operator used on a null value
#0 processColors. (package:tailwind_cli/src/MixinsGenerator.dart:118:33)
#1 _LinkedHashMapMixin.forEach (dart:collection-patch/compact_hash.dart:625:13)
#2 processColors (package:tailwind_cli/src/MixinsGenerator.dart:69:10)
#3 generateColorMixin (package:tailwind_cli/src/MixinsGenerator.dart:51:76)
#4 generate (package:tailwind_cli/src/MixinsGenerator.dart:18:9)
#5 main (file:///Users/enkhdulguun/.pub-cache/hosted/pub.dev/tailwind_cli-0.5.1/bin/build.dart:14:19)
#6 _delayEntrypointInvocation. (dart:isolate-patch/isolate_patch.dart:295:33)
#7 _RawReceivePort._handleMessage (dart:isolate-patch/isolate_patch.dart:192:26)
pub finished with exit code 255

Pub get failed

flutter pub add -d tailwind_cli  
    Because tailwind_cli <0.2.1 depends on dcli ^1.12.4 and tailwind_cli >=0.2.1 <0.5.5 depends on dcli ^1.31.2, tailwind_cli <0.5.5 requires dcli ^1.12.4.
    And because tailwind_cli >=0.5.5 <0.5.6 depends on dcli ^1.36.2 and tailwind_cli >=0.5.6 depends on dcli ^1.31.2, every version of tailwind_cli requires dcli ^1.12.4.
(1) So, because dcli >=0.51.0 <2.0.0-beta.13 depends on validators2 ^3.0.0 which depends on vin_decoder ^0.2.0-nullsafety, every version of tailwind_cli requires vin_decoder ^0.2.0-nullsafety.

    Because no versions of vin_decoder match >=0.2.0-nullsafety <0.2.0-nullsafety and vin_decoder >=0.2.0-nullsafety <0.2.1-nullsafety depends on http ^0.13.0, vin_decoder >=0.2.0-nullsafety <0.2.1-nullsafety requires http ^0.13.0.
    And because vin_decoder >=0.2.1-nullsafety depends on http ^0.13.3, vin_decoder >=0.2.0-nullsafety requires http ^0.13.0.
    And because every version of tailwind_cli requires vin_decoder ^0.2.0-nullsafety (1), every version of tailwind_cli requires http ^0.13.0.
    So, because app depends on both http ^1.1.0 and tailwind_cli any, version solving failed.
flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 3.13.9, on Microsoft Windows [Version 10.0.22621.2506], locale he-IL)
[√] Windows Version (Installed version of Windows is version 10 or higher)
[√] Android toolchain - develop for Android devices (Android SDK version 33.0.2)
[√] Chrome - develop for the web
[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.5.5)
[√] Android Studio (version 2022.2)
[√] VS Code (version 1.83.1)
[√] Connected device (4 available)
[√] Network resources

• No issues found!

Tailwind Build failed

dart run tailwind_cli:build
Building package executable... (7.2s)
Failed to build tailwind_cli:build:
/C:/Users/User/AppData/Local/Pub/Cache/hosted/pub.dev/posix-3.1.0/lib/src/pwd.dart:300:35: Error: Field 'name' cannot be nullable or have type 'Null', it must be `int`, `double`, `Pointer`, or a subtype of `Struct` or `Union`.
  external ffi.Pointer<ffi.Int8>? name;

example is not working

lib/main.dart:42:17: Error: The getter 'TwSpacers' isn't defined for the class 'ExamplePage'.

  • 'ExamplePage' is from 'package:example/main.dart' ('lib/main.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'TwSpacers'.
    TwSpacers.sp2.widthBox,
    ^^^^^^^^^
    lib/main.dart:43:77: Error: The method 'render' isn't defined for the class 'TwText Function(BuildContext)'.
  • 'TwText' is from 'package:tailwind/widgets/TwText.dart' ('tailwind/lib/widgets/TwText.dart').
  • 'BuildContext' is from 'package:flutter/src/widgets/framework.dart' ('/C:/Users/User/AppData/Local/flutter/packages/flutter/lib/src/widgets/framework.dart').Try correcting the name to the name of an existing method, or defining a method named 'render'.
    Text('Item 2 of TwWrap Widget').text.bodyText1.primaryColor.render(),
    ^^^^^^
    lib/main.dart:66:15: Error: The getter 'TwSpacers' isn't defined for the class 'ExamplePage'.
  • 'ExamplePage' is from 'package:example/main.dart' ('lib/main.dart').
    Try correcting the name to the name of an existing getter, or defining a getter or field named 'TwSpacers'.
    TwSpacers.sp3.widthBox,
    ^^^^^^^^^

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.